Class RuleDataSource
java.lang.Object
com.azure.resourcemanager.monitor.models.RuleDataSource
- Direct Known Subclasses:
RuleManagementEventDataSource,RuleMetricDataSource
The resource from which the rule collects its data.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the legacyResourceId property: the legacy resource identifier of the resource the rule monitors.Get the metricNamespace property: the namespace of the metric.Get the resourceLocation property: the location of the resource.Get the resourceUri property: the resource identifier of the resource the rule monitors.voidvalidate()Validates the instance.withLegacyResourceId(String legacyResourceId) Set the legacyResourceId property: the legacy resource identifier of the resource the rule monitors.withMetricNamespace(String metricNamespace) Set the metricNamespace property: the namespace of the metric.withResourceLocation(String resourceLocation) Set the resourceLocation property: the location of the resource.withResourceUri(String resourceUri) Set the resourceUri property: the resource identifier of the resource the rule monitors.
-
Constructor Details
-
RuleDataSource
public RuleDataSource()Creates an instance of RuleDataSource class.
-
-
Method Details
-
resourceUri
Get the resourceUri property: the resource identifier of the resource the rule monitors. **NOTE**: this property cannot be updated for an existing rule.- Returns:
- the resourceUri value.
-
withResourceUri
Set the resourceUri property: the resource identifier of the resource the rule monitors. **NOTE**: this property cannot be updated for an existing rule.- Parameters:
resourceUri- the resourceUri value to set.- Returns:
- the RuleDataSource object itself.
-
legacyResourceId
Get the legacyResourceId property: the legacy resource identifier of the resource the rule monitors. **NOTE**: this property cannot be updated for an existing rule.- Returns:
- the legacyResourceId value.
-
withLegacyResourceId
Set the legacyResourceId property: the legacy resource identifier of the resource the rule monitors. **NOTE**: this property cannot be updated for an existing rule.- Parameters:
legacyResourceId- the legacyResourceId value to set.- Returns:
- the RuleDataSource object itself.
-
resourceLocation
Get the resourceLocation property: the location of the resource.- Returns:
- the resourceLocation value.
-
withResourceLocation
Set the resourceLocation property: the location of the resource.- Parameters:
resourceLocation- the resourceLocation value to set.- Returns:
- the RuleDataSource object itself.
-
metricNamespace
Get the metricNamespace property: the namespace of the metric.- Returns:
- the metricNamespace value.
-
withMetricNamespace
Set the metricNamespace property: the namespace of the metric.- Parameters:
metricNamespace- the metricNamespace value to set.- Returns:
- the RuleDataSource object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-