Class SingleMetricBaselineInner
java.lang.Object
com.azure.resourcemanager.monitor.fluent.models.SingleMetricBaselineInner
- All Implemented Interfaces:
com.azure.json.JsonSerializable<SingleMetricBaselineInner>
public final class SingleMetricBaselineInner
extends Object
implements com.azure.json.JsonSerializable<SingleMetricBaselineInner>
The baseline results of a single metric.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of SingleMetricBaselineInner class. -
Method Summary
Modifier and TypeMethodDescriptionGet the baselines property: The baseline for each time series that was queried.static SingleMetricBaselineInner
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of SingleMetricBaselineInner from the JsonReader.id()
Get the id property: The metric baseline Id.interval()
Get the interval property: The interval (window size) for which the metric data was returned in.name()
Get the name property: The name of the metric for which the baselines were retrieved.Get the namespace property: The namespace of the metrics been queried.timespan()
Get the timespan property: The timespan for which the data was retrieved.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) type()
Get the type property: The resource type of the metric baseline resource.void
validate()
Validates the instance.withBaselines
(List<TimeSeriesBaseline> baselines) Set the baselines property: The baseline for each time series that was queried.Set the id property: The metric baseline Id.withInterval
(Duration interval) Set the interval property: The interval (window size) for which the metric data was returned in.Set the name property: The name of the metric for which the baselines were retrieved.withNamespace
(String namespace) Set the namespace property: The namespace of the metrics been queried.withTimespan
(String timespan) Set the timespan property: The timespan for which the data was retrieved.Set the type property: The resource type of the metric baseline resource.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
SingleMetricBaselineInner
public SingleMetricBaselineInner()Creates an instance of SingleMetricBaselineInner class.
-
-
Method Details
-
id
Get the id property: The metric baseline Id.- Returns:
- the id value.
-
withId
Set the id property: The metric baseline Id.- Parameters:
id
- the id value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
type
Get the type property: The resource type of the metric baseline resource.- Returns:
- the type value.
-
withType
Set the type property: The resource type of the metric baseline resource.- Parameters:
type
- the type value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
name
Get the name property: The name of the metric for which the baselines were retrieved.- Returns:
- the name value.
-
withName
Set the name property: The name of the metric for which the baselines were retrieved.- Parameters:
name
- the name value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
timespan
Get the timespan property: The timespan for which the data was retrieved. Its value consists of two datetimes concatenated, separated by '/'. This may be adjusted in the future and returned back from what was originally requested.- Returns:
- the timespan value.
-
withTimespan
Set the timespan property: The timespan for which the data was retrieved. Its value consists of two datetimes concatenated, separated by '/'. This may be adjusted in the future and returned back from what was originally requested.- Parameters:
timespan
- the timespan value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
interval
Get the interval property: The interval (window size) for which the metric data was returned in. This may be adjusted in the future and returned back from what was originally requested. This is not present if a metadata request was made.- Returns:
- the interval value.
-
withInterval
Set the interval property: The interval (window size) for which the metric data was returned in. This may be adjusted in the future and returned back from what was originally requested. This is not present if a metadata request was made.- Parameters:
interval
- the interval value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
namespace
Get the namespace property: The namespace of the metrics been queried.- Returns:
- the namespace value.
-
withNamespace
Set the namespace property: The namespace of the metrics been queried.- Parameters:
namespace
- the namespace value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
baselines
Get the baselines property: The baseline for each time series that was queried.- Returns:
- the baselines value.
-
withBaselines
Set the baselines property: The baseline for each time series that was queried.- Parameters:
baselines
- the baselines value to set.- Returns:
- the SingleMetricBaselineInner object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
toJson
- Specified by:
toJson
in interfacecom.azure.json.JsonSerializable<SingleMetricBaselineInner>
- Throws:
IOException
-
fromJson
public static SingleMetricBaselineInner fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of SingleMetricBaselineInner from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of SingleMetricBaselineInner if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException
- If the deserialized JSON object was missing any required properties.IOException
- If an error occurs while reading the SingleMetricBaselineInner.
-