Class MetricSettings
java.lang.Object
com.microsoft.azure.management.monitor.MetricSettings
Part of MultiTenantDiagnosticSettings. Specifies the settings for a
particular metric.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncategory()
Get name of a Diagnostic Metric category for a resource type this setting is applied to.boolean
enabled()
Get a value indicating whether this category is enabled.Get the retention policy for this category.org.joda.time.Period
Get the timegrain of the metric in ISO8601 format.withCategory
(String category) Set name of a Diagnostic Metric category for a resource type this setting is applied to.withEnabled
(boolean enabled) Set a value indicating whether this category is enabled.withRetentionPolicy
(RetentionPolicy retentionPolicy) Set the retention policy for this category.withTimeGrain
(org.joda.time.Period timeGrain) Set the timegrain of the metric in ISO8601 format.
-
Constructor Details
-
MetricSettings
public MetricSettings()
-
-
Method Details
-
timeGrain
public org.joda.time.Period timeGrain()Get the timegrain of the metric in ISO8601 format.- Returns:
- the timeGrain value
-
withTimeGrain
Set the timegrain of the metric in ISO8601 format.- Parameters:
timeGrain
- the timeGrain value to set- Returns:
- the MetricSettings object itself.
-
category
Get name of a Diagnostic Metric category for a resource type this setting is applied to. To obtain the list of Diagnostic metric categories for a resource, first perform a GET diagnostic settings operation.- Returns:
- the category value
-
withCategory
Set name of a Diagnostic Metric category for a resource type this setting is applied to. To obtain the list of Diagnostic metric categories for a resource, first perform a GET diagnostic settings operation.- Parameters:
category
- the category value to set- Returns:
- the MetricSettings object itself.
-
enabled
public boolean enabled()Get a value indicating whether this category is enabled.- Returns:
- the enabled value
-
withEnabled
Set a value indicating whether this category is enabled.- Parameters:
enabled
- the enabled value to set- Returns:
- the MetricSettings object itself.
-
retentionPolicy
Get the retention policy for this category.- Returns:
- the retentionPolicy value
-
withRetentionPolicy
Set the retention policy for this category.- Parameters:
retentionPolicy
- the retentionPolicy value to set- Returns:
- the MetricSettings object itself.
-