public final class MetricsQueryResult extends Object
Constructor and Description |
---|
MetricsQueryResult(Integer cost,
com.azure.core.experimental.models.TimeInterval timeInterval,
Duration granularity,
String namespace,
String resourceRegion,
List<MetricResult> metrics)
Creates an instance of the response to a metrics query.
|
Modifier and Type | Method and Description |
---|---|
Integer |
getCost()
Returns the integer value representing the cost of the query, for data case.
|
Duration |
getGranularity()
Returns the interval (window size) for which the metric data was returned in.
|
List<MetricResult> |
getMetrics()
Returns the value of the collection.
|
MetricResult |
getMetrics(String metricName)
Returns the metric result for the
metricName . |
String |
getNamespace()
Returns the namespace of the metrics been queried
|
String |
getResourceRegion()
Returns the region of the resource been queried for metrics.
|
com.azure.core.experimental.models.TimeInterval |
getTimeInterval()
Returns the time interval for which the data was retrieved.
|
public MetricsQueryResult(Integer cost, com.azure.core.experimental.models.TimeInterval timeInterval, Duration granularity, String namespace, String resourceRegion, List<MetricResult> metrics)
cost
- the integer value representing the cost of the query, for data case.timeInterval
- the time interval for which the data was retrieved.granularity
- the interval (window size) for which the metric data was returned in.namespace
- the namespace of the metrics been queried.resourceRegion
- the region of the resource been queried for metrics.metrics
- the value of the collection.public Integer getCost()
public com.azure.core.experimental.models.TimeInterval getTimeInterval()
public Duration getGranularity()
public String getNamespace()
public String getResourceRegion()
public List<MetricResult> getMetrics()
public MetricResult getMetrics(String metricName)
metricName
.metricName
- The name of the metric to look up the result for.MetricResult
for metricName
if found, null
otherwise.Copyright © 2021 Microsoft Corporation. All rights reserved.