Class ThresholdRuleCondition
- java.lang.Object
-
- com.microsoft.azure.management.monitor.RuleCondition
-
- com.microsoft.azure.management.monitor.ThresholdRuleCondition
-
public class ThresholdRuleCondition extends RuleCondition
A rule condition based on a metric crossing a threshold.
-
-
Constructor Summary
Constructors Constructor Description ThresholdRuleCondition()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConditionOperatoroperator()Get the operator used to compare the data and the threshold.doublethreshold()Get the threshold value that activates the alert.TimeAggregationOperatortimeAggregation()Get the time aggregation operator.org.joda.time.PeriodwindowSize()Get the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold.ThresholdRuleConditionwithOperator(ConditionOperator operator)Set the operator used to compare the data and the threshold.ThresholdRuleConditionwithThreshold(double threshold)Set the threshold value that activates the alert.ThresholdRuleConditionwithTimeAggregation(TimeAggregationOperator timeAggregation)Set the time aggregation operator.ThresholdRuleConditionwithWindowSize(org.joda.time.Period windowSize)Set the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold.-
Methods inherited from class com.microsoft.azure.management.monitor.RuleCondition
dataSource, withDataSource
-
-
-
-
Method Detail
-
operator
public ConditionOperator operator()
Get the operator used to compare the data and the threshold. Possible values include: 'GreaterThan', 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'.- Returns:
- the operator value
-
withOperator
public ThresholdRuleCondition withOperator(ConditionOperator operator)
Set the operator used to compare the data and the threshold. Possible values include: 'GreaterThan', 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'.- Parameters:
operator- the operator value to set- Returns:
- the ThresholdRuleCondition object itself.
-
threshold
public double threshold()
Get the threshold value that activates the alert.- Returns:
- the threshold value
-
withThreshold
public ThresholdRuleCondition withThreshold(double threshold)
Set the threshold value that activates the alert.- Parameters:
threshold- the threshold value to set- Returns:
- the ThresholdRuleCondition object itself.
-
windowSize
public org.joda.time.Period windowSize()
Get the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold. If specified then it must be between 5 minutes and 1 day.- Returns:
- the windowSize value
-
withWindowSize
public ThresholdRuleCondition withWindowSize(org.joda.time.Period windowSize)
Set the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold. If specified then it must be between 5 minutes and 1 day.- Parameters:
windowSize- the windowSize value to set- Returns:
- the ThresholdRuleCondition object itself.
-
timeAggregation
public TimeAggregationOperator timeAggregation()
Get the time aggregation operator. How the data that are collected should be combined over time. The default value is the PrimaryAggregationType of the Metric. Possible values include: 'Average', 'Minimum', 'Maximum', 'Total', 'Last'.- Returns:
- the timeAggregation value
-
withTimeAggregation
public ThresholdRuleCondition withTimeAggregation(TimeAggregationOperator timeAggregation)
Set the time aggregation operator. How the data that are collected should be combined over time. The default value is the PrimaryAggregationType of the Metric. Possible values include: 'Average', 'Minimum', 'Maximum', 'Total', 'Last'.- Parameters:
timeAggregation- the timeAggregation value to set- Returns:
- the ThresholdRuleCondition object itself.
-
-