Class MetricSpecification
- java.lang.Object
-
- com.azure.resourcemanager.appplatform.models.MetricSpecification
-
public final class MetricSpecification extends Object
Specifications of the Metrics for Azure Monitoring.
-
-
Constructor Summary
Constructors Constructor Description MetricSpecification()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringaggregationType()Get the aggregationType property: Only provide one value for this field.Stringcategory()Get the category property: Name of the metric category that the metric belongs to.List<MetricDimension>dimensions()Get the dimensions property: Dimensions of the metric.StringdisplayDescription()Get the displayDescription property: Localized friendly description of the metric.StringdisplayName()Get the displayName property: Localized friendly display name of the metric.BooleanfillGapWithZero()Get the fillGapWithZero property: Optional.Stringname()Get the name property: Name of the metric.List<String>supportedAggregationTypes()Get the supportedAggregationTypes property: Supported aggregation types.List<String>supportedTimeGrainTypes()Get the supportedTimeGrainTypes property: Supported time grain types.Stringunit()Get the unit property: Unit that makes sense for the metric.voidvalidate()Validates the instance.MetricSpecificationwithAggregationType(String aggregationType)Set the aggregationType property: Only provide one value for this field.MetricSpecificationwithCategory(String category)Set the category property: Name of the metric category that the metric belongs to.MetricSpecificationwithDimensions(List<MetricDimension> dimensions)Set the dimensions property: Dimensions of the metric.MetricSpecificationwithDisplayDescription(String displayDescription)Set the displayDescription property: Localized friendly description of the metric.MetricSpecificationwithDisplayName(String displayName)Set the displayName property: Localized friendly display name of the metric.MetricSpecificationwithFillGapWithZero(Boolean fillGapWithZero)Set the fillGapWithZero property: Optional.MetricSpecificationwithName(String name)Set the name property: Name of the metric.MetricSpecificationwithSupportedAggregationTypes(List<String> supportedAggregationTypes)Set the supportedAggregationTypes property: Supported aggregation types.MetricSpecificationwithSupportedTimeGrainTypes(List<String> supportedTimeGrainTypes)Set the supportedTimeGrainTypes property: Supported time grain types.MetricSpecificationwithUnit(String unit)Set the unit property: Unit that makes sense for the metric.
-
-
-
Method Detail
-
name
public String name()
Get the name property: Name of the metric.- Returns:
- the name value.
-
withName
public MetricSpecification withName(String name)
Set the name property: Name of the metric.- Parameters:
name- the name value to set.- Returns:
- the MetricSpecification object itself.
-
displayName
public String displayName()
Get the displayName property: Localized friendly display name of the metric.- Returns:
- the displayName value.
-
withDisplayName
public MetricSpecification withDisplayName(String displayName)
Set the displayName property: Localized friendly display name of the metric.- Parameters:
displayName- the displayName value to set.- Returns:
- the MetricSpecification object itself.
-
displayDescription
public String displayDescription()
Get the displayDescription property: Localized friendly description of the metric.- Returns:
- the displayDescription value.
-
withDisplayDescription
public MetricSpecification withDisplayDescription(String displayDescription)
Set the displayDescription property: Localized friendly description of the metric.- Parameters:
displayDescription- the displayDescription value to set.- Returns:
- the MetricSpecification object itself.
-
unit
public String unit()
Get the unit property: Unit that makes sense for the metric.- Returns:
- the unit value.
-
withUnit
public MetricSpecification withUnit(String unit)
Set the unit property: Unit that makes sense for the metric.- Parameters:
unit- the unit value to set.- Returns:
- the MetricSpecification object itself.
-
category
public String category()
Get the category property: Name of the metric category that the metric belongs to. A metric can only belong to a single category.- Returns:
- the category value.
-
withCategory
public MetricSpecification withCategory(String category)
Set the category property: Name of the metric category that the metric belongs to. A metric can only belong to a single category.- Parameters:
category- the category value to set.- Returns:
- the MetricSpecification object itself.
-
aggregationType
public String aggregationType()
Get the aggregationType property: Only provide one value for this field. Valid values: Average, Minimum, Maximum, Total, Count.- Returns:
- the aggregationType value.
-
withAggregationType
public MetricSpecification withAggregationType(String aggregationType)
Set the aggregationType property: Only provide one value for this field. Valid values: Average, Minimum, Maximum, Total, Count.- Parameters:
aggregationType- the aggregationType value to set.- Returns:
- the MetricSpecification object itself.
-
supportedAggregationTypes
public List<String> supportedAggregationTypes()
Get the supportedAggregationTypes property: Supported aggregation types.- Returns:
- the supportedAggregationTypes value.
-
withSupportedAggregationTypes
public MetricSpecification withSupportedAggregationTypes(List<String> supportedAggregationTypes)
Set the supportedAggregationTypes property: Supported aggregation types.- Parameters:
supportedAggregationTypes- the supportedAggregationTypes value to set.- Returns:
- the MetricSpecification object itself.
-
supportedTimeGrainTypes
public List<String> supportedTimeGrainTypes()
Get the supportedTimeGrainTypes property: Supported time grain types.- Returns:
- the supportedTimeGrainTypes value.
-
withSupportedTimeGrainTypes
public MetricSpecification withSupportedTimeGrainTypes(List<String> supportedTimeGrainTypes)
Set the supportedTimeGrainTypes property: Supported time grain types.- Parameters:
supportedTimeGrainTypes- the supportedTimeGrainTypes value to set.- Returns:
- the MetricSpecification object itself.
-
fillGapWithZero
public Boolean fillGapWithZero()
Get the fillGapWithZero property: Optional. If set to true, then zero will be returned for time duration where no metric is emitted/published.- Returns:
- the fillGapWithZero value.
-
withFillGapWithZero
public MetricSpecification withFillGapWithZero(Boolean fillGapWithZero)
Set the fillGapWithZero property: Optional. If set to true, then zero will be returned for time duration where no metric is emitted/published.- Parameters:
fillGapWithZero- the fillGapWithZero value to set.- Returns:
- the MetricSpecification object itself.
-
dimensions
public List<MetricDimension> dimensions()
Get the dimensions property: Dimensions of the metric.- Returns:
- the dimensions value.
-
withDimensions
public MetricSpecification withDimensions(List<MetricDimension> dimensions)
Set the dimensions property: Dimensions of the metric.- Parameters:
dimensions- the dimensions value to set.- Returns:
- the MetricSpecification object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-