Class QuotaProperties
java.lang.Object
com.azure.resourcemanager.reservations.models.QuotaProperties
- All Implemented Interfaces:
com.azure.json.JsonSerializable<QuotaProperties>
public final class QuotaProperties
extends Object
implements com.azure.json.JsonSerializable<QuotaProperties>
Quota properties for the resource.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the currentValue property: Current usage value for the resource.static QuotaProperties
fromJson
(com.azure.json.JsonReader jsonReader) Reads an instance of QuotaProperties from the JsonReader.limit()
Get the limit property: Quota properties.name()
Get the name property: Name of the resource provide by the resource provider.Get the properties property: Additional properties for the specified resource provider.Get the quotaPeriod property: The time period over which the quota usage values are summarized.Get the resourceType property: The name of the resource type.com.azure.json.JsonWriter
toJson
(com.azure.json.JsonWriter jsonWriter) unit()
Get the unit property: The limit units, such as **count** and **bytes**.void
validate()
Validates the instance.Set the limit property: Quota properties.withName
(ResourceName name) Set the name property: Name of the resource provide by the resource provider.withProperties
(Object properties) Set the properties property: Additional properties for the specified resource provider.withResourceType
(ResourceType resourceType) Set the resourceType property: The name of the resource type.Set the unit property: The limit units, such as **count** and **bytes**.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
-
QuotaProperties
public QuotaProperties()Creates an instance of QuotaProperties class.
-
-
Method Details
-
limit
Get the limit property: Quota properties.- Returns:
- the limit value.
-
withLimit
Set the limit property: Quota properties.- Parameters:
limit
- the limit value to set.- Returns:
- the QuotaProperties object itself.
-
currentValue
Get the currentValue property: Current usage value for the resource.- Returns:
- the currentValue value.
-
unit
Get the unit property: The limit units, such as **count** and **bytes**. Use the unit field provided in the response of the GET quota operation.- Returns:
- the unit value.
-
withUnit
Set the unit property: The limit units, such as **count** and **bytes**. Use the unit field provided in the response of the GET quota operation.- Parameters:
unit
- the unit value to set.- Returns:
- the QuotaProperties object itself.
-
name
Get the name property: Name of the resource provide by the resource provider. Use this property for quotaRequests resource operations.- Returns:
- the name value.
-
withName
Set the name property: Name of the resource provide by the resource provider. Use this property for quotaRequests resource operations.- Parameters:
name
- the name value to set.- Returns:
- the QuotaProperties object itself.
-
resourceType
Get the resourceType property: The name of the resource type.- Returns:
- the resourceType value.
-
withResourceType
Set the resourceType property: The name of the resource type.- Parameters:
resourceType
- the resourceType value to set.- Returns:
- the QuotaProperties object itself.
-
quotaPeriod
Get the quotaPeriod property: The time period over which the quota usage values are summarized. For example, P1D (per one day), PT1M (per one minute), and PT1S (per one second). This parameter is optional because, for some resources such as compute, the time period is irrelevant.- Returns:
- the quotaPeriod value.
-
properties
Get the properties property: Additional properties for the specified resource provider.- Returns:
- the properties value.
-
withProperties
Set the properties property: Additional properties for the specified resource provider.- Parameters:
properties
- the properties value to set.- Returns:
- the QuotaProperties 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<QuotaProperties>
- Throws:
IOException
-
fromJson
Reads an instance of QuotaProperties from the JsonReader.- Parameters:
jsonReader
- The JsonReader being read.- Returns:
- An instance of QuotaProperties 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 QuotaProperties.
-