Class QuotaCounterContractInner

java.lang.Object
com.azure.resourcemanager.apimanagement.fluent.models.QuotaCounterContractInner
All Implemented Interfaces:
com.azure.json.JsonSerializable<QuotaCounterContractInner>

public final class QuotaCounterContractInner extends Object implements com.azure.json.JsonSerializable<QuotaCounterContractInner>
Quota counter details.
  • Constructor Details

    • QuotaCounterContractInner

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

    • counterKey

      public String counterKey()
      Get the counterKey property: The Key value of the Counter. Must not be empty.
      Returns:
      the counterKey value.
    • withCounterKey

      public QuotaCounterContractInner withCounterKey(String counterKey)
      Set the counterKey property: The Key value of the Counter. Must not be empty.
      Parameters:
      counterKey - the counterKey value to set.
      Returns:
      the QuotaCounterContractInner object itself.
    • periodKey

      public String periodKey()
      Get the periodKey property: Identifier of the Period for which the counter was collected. Must not be empty.
      Returns:
      the periodKey value.
    • withPeriodKey

      public QuotaCounterContractInner withPeriodKey(String periodKey)
      Set the periodKey property: Identifier of the Period for which the counter was collected. Must not be empty.
      Parameters:
      periodKey - the periodKey value to set.
      Returns:
      the QuotaCounterContractInner object itself.
    • periodStartTime

      public OffsetDateTime periodStartTime()
      Get the periodStartTime property: The date of the start of Counter Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Returns:
      the periodStartTime value.
    • withPeriodStartTime

      public QuotaCounterContractInner withPeriodStartTime(OffsetDateTime periodStartTime)
      Set the periodStartTime property: The date of the start of Counter Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Parameters:
      periodStartTime - the periodStartTime value to set.
      Returns:
      the QuotaCounterContractInner object itself.
    • periodEndTime

      public OffsetDateTime periodEndTime()
      Get the periodEndTime property: The date of the end of Counter Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Returns:
      the periodEndTime value.
    • withPeriodEndTime

      public QuotaCounterContractInner withPeriodEndTime(OffsetDateTime periodEndTime)
      Set the periodEndTime property: The date of the end of Counter Period. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Parameters:
      periodEndTime - the periodEndTime value to set.
      Returns:
      the QuotaCounterContractInner object itself.
    • value

      Get the value property: Quota Value Properties.
      Returns:
      the value value.
    • withValue

      Set the value property: Quota Value Properties.
      Parameters:
      value - the value value to set.
      Returns:
      the QuotaCounterContractInner object itself.
    • 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<QuotaCounterContractInner>
      Throws:
      IOException
    • fromJson

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