Class RecommendedActionMetricInfo
java.lang.Object
com.azure.resourcemanager.sql.models.RecommendedActionMetricInfo
- All Implemented Interfaces:
com.azure.json.JsonSerializable<RecommendedActionMetricInfo>
public final class RecommendedActionMetricInfo
extends Object
implements com.azure.json.JsonSerializable<RecommendedActionMetricInfo>
Contains time series of various impacted metrics for an Azure SQL Database, Server or Elastic Pool Recommended
Action.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of RecommendedActionMetricInfo class. -
Method Summary
Modifier and TypeMethodDescriptionstatic RecommendedActionMetricInfofromJson(com.azure.json.JsonReader jsonReader) Reads an instance of RecommendedActionMetricInfo from the JsonReader.Get the metricName property: Gets the name of the metric. e.g., CPU, Number of Queries.Get the startTime property: Gets the start time of time interval given by this MetricInfo.Get the timeGrain property: Gets the duration of time interval for the value given by this MetricInfo. e.g., PT1H (1 hour).com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) unit()Get the unit property: Gets the unit in which metric is measured. e.g., DTU, Frequency.voidvalidate()Validates the instance.value()Get the value property: Gets the value of the metric in the time interval given by this MetricInfo.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
RecommendedActionMetricInfo
public RecommendedActionMetricInfo()Creates an instance of RecommendedActionMetricInfo class.
-
-
Method Details
-
metricName
Get the metricName property: Gets the name of the metric. e.g., CPU, Number of Queries.- Returns:
- the metricName value.
-
unit
Get the unit property: Gets the unit in which metric is measured. e.g., DTU, Frequency.- Returns:
- the unit value.
-
timeGrain
Get the timeGrain property: Gets the duration of time interval for the value given by this MetricInfo. e.g., PT1H (1 hour).- Returns:
- the timeGrain value.
-
startTime
Get the startTime property: Gets the start time of time interval given by this MetricInfo.- Returns:
- the startTime value.
-
value
Get the value property: Gets the value of the metric in the time interval given by this MetricInfo.- Returns:
- the value value.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<RecommendedActionMetricInfo>- Throws:
IOException
-
fromJson
public static RecommendedActionMetricInfo fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of RecommendedActionMetricInfo from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of RecommendedActionMetricInfo if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException- If an error occurs while reading the RecommendedActionMetricInfo.
-