MetricDefinitionInner Class
- java.
lang. Object - com.
azure. resourcemanager. monitor. fluent. models. MetricDefinitionInner
- com.
Implements
public final class MetricDefinitionInner
implements JsonSerializable<MetricDefinitionInner>
Metric definition class specifies the metadata for a metric.
Constructor Summary
Constructor | Description |
---|---|
MetricDefinitionInner() |
Creates an instance of Metric |
Method Summary
Modifier and Type | Method and Description |
---|---|
String |
category()
Get the category property: Custom category name for this metric. |
List<Localizable |
dimensions()
Get the dimensions property: the name and the display name of the dimension, i. |
String |
displayDescription()
Get the display |
static
Metric |
fromJson(JsonReader jsonReader)
Reads an instance of Metric |
String |
id()
Get the id property: the resource identifier of the metric definition. |
Boolean |
isDimensionRequired()
Get the is |
List<Metric |
metricAvailabilities()
Get the metric |
Metric |
metricClass()
Get the metric |
Localizable |
name()
Get the name property: the name and the display name of the metric, i. |
String |
namespace()
Get the namespace property: the namespace the metric belongs to. |
Aggregation |
primaryAggregationType()
Get the primary |
String |
resourceId()
Get the resource |
List<Aggregation |
supportedAggregationTypes()
Get the supported |
Json |
toJson(JsonWriter jsonWriter) |
Unit |
unit()
Get the unit property: The unit of the metric. |
void |
validate()
Validates the instance. |
Metric |
withCategory(String category)
Set the category property: Custom category name for this metric. |
Metric |
withDimensions(List<LocalizableStringInner> dimensions)
Set the dimensions property: the name and the display name of the dimension, i. |
Metric |
withDisplayDescription(String displayDescription)
Set the display |
Metric |
withId(String id)
Set the id property: the resource identifier of the metric definition. |
Metric |
withIsDimensionRequired(Boolean isDimensionRequired)
Set the is |
Metric |
withMetricAvailabilities(List<MetricAvailability> metricAvailabilities)
Set the metric |
Metric |
withMetricClass(MetricClass metricClass)
Set the metric |
Metric |
withName(LocalizableStringInner name)
Set the name property: the name and the display name of the metric, i. |
Metric |
withNamespace(String namespace)
Set the namespace property: the namespace the metric belongs to. |
Metric |
withPrimaryAggregationType(AggregationType primaryAggregationType)
Set the primary |
Metric |
withResourceId(String resourceId)
Set the resource |
Metric |
withSupportedAggregationTypes(List<AggregationType> supportedAggregationTypes)
Set the supported |
Metric |
withUnit(Unit unit)
Set the unit property: The unit of the metric. |
Methods inherited from java.lang.Object
Constructor Details
MetricDefinitionInner
public MetricDefinitionInner()
Creates an instance of MetricDefinitionInner class.
Method Details
category
public String category()
Get the category property: Custom category name for this metric.
Returns:
dimensions
public List
Get the dimensions property: the name and the display name of the dimension, i.e. it is a localizable string.
Returns:
displayDescription
public String displayDescription()
Get the displayDescription property: Detailed description of this metric.
Returns:
fromJson
public static MetricDefinitionInner fromJson(JsonReader jsonReader)
Reads an instance of MetricDefinitionInner from the JsonReader.
Parameters:
Returns:
Throws:
id
public String id()
Get the id property: the resource identifier of the metric definition.
Returns:
isDimensionRequired
public Boolean isDimensionRequired()
Get the isDimensionRequired property: Flag to indicate whether the dimension is required.
Returns:
metricAvailabilities
public List
Get the metricAvailabilities property: the collection of what aggregation intervals are available to be queried.
Returns:
metricClass
public MetricClass metricClass()
Get the metricClass property: The class of the metric.
Returns:
name
public LocalizableStringInner name()
Get the name property: the name and the display name of the metric, i.e. it is a localizable string.
Returns:
namespace
public String namespace()
Get the namespace property: the namespace the metric belongs to.
Returns:
primaryAggregationType
public AggregationType primaryAggregationType()
Get the primaryAggregationType property: the primary aggregation type value defining how to use the values for display.
Returns:
resourceId
public String resourceId()
Get the resourceId property: the resource identifier of the resource that emitted the metric.
Returns:
supportedAggregationTypes
public List
Get the supportedAggregationTypes property: the collection of what aggregation types are supported.
Returns:
toJson
unit
public Unit unit()
Get the unit property: The unit of the metric.
Returns:
validate
public void validate()
Validates the instance.
withCategory
public MetricDefinitionInner withCategory(String category)
Set the category property: Custom category name for this metric.
Parameters:
Returns:
withDimensions
public MetricDefinitionInner withDimensions(List
Set the dimensions property: the name and the display name of the dimension, i.e. it is a localizable string.
Parameters:
Returns:
withDisplayDescription
public MetricDefinitionInner withDisplayDescription(String displayDescription)
Set the displayDescription property: Detailed description of this metric.
Parameters:
Returns:
withId
public MetricDefinitionInner withId(String id)
Set the id property: the resource identifier of the metric definition.
Parameters:
Returns:
withIsDimensionRequired
public MetricDefinitionInner withIsDimensionRequired(Boolean isDimensionRequired)
Set the isDimensionRequired property: Flag to indicate whether the dimension is required.
Parameters:
Returns:
withMetricAvailabilities
public MetricDefinitionInner withMetricAvailabilities(List
Set the metricAvailabilities property: the collection of what aggregation intervals are available to be queried.
Parameters:
Returns:
withMetricClass
public MetricDefinitionInner withMetricClass(MetricClass metricClass)
Set the metricClass property: The class of the metric.
Parameters:
Returns:
withName
public MetricDefinitionInner withName(LocalizableStringInner name)
Set the name property: the name and the display name of the metric, i.e. it is a localizable string.
Parameters:
Returns:
withNamespace
public MetricDefinitionInner withNamespace(String namespace)
Set the namespace property: the namespace the metric belongs to.
Parameters:
Returns:
withPrimaryAggregationType
public MetricDefinitionInner withPrimaryAggregationType(AggregationType primaryAggregationType)
Set the primaryAggregationType property: the primary aggregation type value defining how to use the values for display.
Parameters:
Returns:
withResourceId
public MetricDefinitionInner withResourceId(String resourceId)
Set the resourceId property: the resource identifier of the resource that emitted the metric.
Parameters:
Returns:
withSupportedAggregationTypes
public MetricDefinitionInner withSupportedAggregationTypes(List
Set the supportedAggregationTypes property: the collection of what aggregation types are supported.
Parameters:
Returns:
withUnit
public MetricDefinitionInner withUnit(Unit unit)
Set the unit property: The unit of the metric.
Parameters:
Returns:
Applies to
Azure SDK for Java