Class ReservationToPurchaseExchange

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

public final class ReservationToPurchaseExchange extends Object implements com.azure.json.JsonSerializable<ReservationToPurchaseExchange>
Reservation purchase details.
  • Constructor Details

    • ReservationToPurchaseExchange

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

    • reservationOrderId

      public String reservationOrderId()
      Get the reservationOrderId property: Fully qualified id of the reservationOrder being purchased.
      Returns:
      the reservationOrderId value.
    • withReservationOrderId

      public ReservationToPurchaseExchange withReservationOrderId(String reservationOrderId)
      Set the reservationOrderId property: Fully qualified id of the reservationOrder being purchased.
      Parameters:
      reservationOrderId - the reservationOrderId value to set.
      Returns:
      the ReservationToPurchaseExchange object itself.
    • reservationId

      public String reservationId()
      Get the reservationId property: Fully qualified id of the reservation being purchased. This value is only guaranteed to be non-null if the purchase is successful.
      Returns:
      the reservationId value.
    • withReservationId

      public ReservationToPurchaseExchange withReservationId(String reservationId)
      Set the reservationId property: Fully qualified id of the reservation being purchased. This value is only guaranteed to be non-null if the purchase is successful.
      Parameters:
      reservationId - the reservationId value to set.
      Returns:
      the ReservationToPurchaseExchange object itself.
    • properties

      public PurchaseRequest properties()
      Get the properties property: The request for reservation purchase.
      Returns:
      the properties value.
    • withProperties

      public ReservationToPurchaseExchange withProperties(PurchaseRequest properties)
      Set the properties property: The request for reservation purchase.
      Parameters:
      properties - the properties value to set.
      Returns:
      the ReservationToPurchaseExchange object itself.
    • billingCurrencyTotal

      public Price billingCurrencyTotal()
      Get the billingCurrencyTotal property: Pricing information containing the amount and the currency code.
      Returns:
      the billingCurrencyTotal value.
    • withBillingCurrencyTotal

      public ReservationToPurchaseExchange withBillingCurrencyTotal(Price billingCurrencyTotal)
      Set the billingCurrencyTotal property: Pricing information containing the amount and the currency code.
      Parameters:
      billingCurrencyTotal - the billingCurrencyTotal value to set.
      Returns:
      the ReservationToPurchaseExchange object itself.
    • status

      public OperationStatus status()
      Get the status property: Status of the individual operation.
      Returns:
      the status value.
    • withStatus

      public ReservationToPurchaseExchange withStatus(OperationStatus status)
      Set the status property: Status of the individual operation.
      Parameters:
      status - the status value to set.
      Returns:
      the ReservationToPurchaseExchange 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<ReservationToPurchaseExchange>
      Throws:
      IOException
    • fromJson

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