java.lang.Object
com.azure.resourcemanager.reservations.models.SubRequest
All Implemented Interfaces:
com.azure.json.JsonSerializable<SubRequest>

public final class SubRequest extends Object implements com.azure.json.JsonSerializable<SubRequest>
The sub-request submitted with the quota request.
  • Constructor Details

    • SubRequest

      public SubRequest()
      Creates an instance of SubRequest class.
  • Method Details

    • limit

      public Integer limit()
      Get the limit property: Quota (resource limit).
      Returns:
      the limit value.
    • name

      public ResourceName name()
      Get the name property: The resource name.
      Returns:
      the name value.
    • withName

      public SubRequest withName(ResourceName name)
      Set the name property: The resource name.
      Parameters:
      name - the name value to set.
      Returns:
      the SubRequest object itself.
    • resourceType

      public String resourceType()
      Get the resourceType property: Resource type for which the quota check was made.
      Returns:
      the resourceType value.
    • unit

      public String 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

      public SubRequest withUnit(String unit)
      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 SubRequest object itself.
    • provisioningState

      public QuotaRequestState provisioningState()
      Get the provisioningState property: The quota request status.
      Returns:
      the provisioningState value.
    • withProvisioningState

      public SubRequest withProvisioningState(QuotaRequestState provisioningState)
      Set the provisioningState property: The quota request status.
      Parameters:
      provisioningState - the provisioningState value to set.
      Returns:
      the SubRequest object itself.
    • message

      public String message()
      Get the message property: User-friendly status message.
      Returns:
      the message value.
    • subRequestId

      public String subRequestId()
      Get the subRequestId property: Sub request ID for individual request.
      Returns:
      the subRequestId value.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<SubRequest>
      Throws:
      IOException
    • fromJson

      public static SubRequest fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of SubRequest from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of SubRequest 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 SubRequest.