@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Purchase extends Object implements Serializable, Cloneable
Describes the result of the purchase.
Constructor and Description |
---|
Purchase() |
Modifier and Type | Method and Description |
---|---|
Purchase |
clone() |
boolean |
equals(Object obj) |
String |
getCurrencyCode()
The currency in which the
UpfrontPrice and HourlyPrice amounts are specified. |
Integer |
getDuration()
The duration of the reservation's term in seconds.
|
List<String> |
getHostIdSet()
The IDs of the Dedicated Hosts associated with the reservation.
|
String |
getHostReservationId()
The ID of the reservation.
|
String |
getHourlyPrice()
The hourly price of the reservation per hour.
|
String |
getInstanceFamily()
The instance family on the Dedicated Host that the reservation can be associated with.
|
String |
getPaymentOption()
The payment option for the reservation.
|
String |
getUpfrontPrice()
The upfront price of the reservation.
|
int |
hashCode() |
void |
setCurrencyCode(CurrencyCodeValues currencyCode)
The currency in which the
UpfrontPrice and HourlyPrice amounts are specified. |
void |
setCurrencyCode(String currencyCode)
The currency in which the
UpfrontPrice and HourlyPrice amounts are specified. |
void |
setDuration(Integer duration)
The duration of the reservation's term in seconds.
|
void |
setHostIdSet(Collection<String> hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
|
void |
setHostReservationId(String hostReservationId)
The ID of the reservation.
|
void |
setHourlyPrice(String hourlyPrice)
The hourly price of the reservation per hour.
|
void |
setInstanceFamily(String instanceFamily)
The instance family on the Dedicated Host that the reservation can be associated with.
|
void |
setPaymentOption(PaymentOption paymentOption)
The payment option for the reservation.
|
void |
setPaymentOption(String paymentOption)
The payment option for the reservation.
|
void |
setUpfrontPrice(String upfrontPrice)
The upfront price of the reservation.
|
String |
toString()
Returns a string representation of this object; useful for testing and debugging.
|
Purchase |
withCurrencyCode(CurrencyCodeValues currencyCode)
The currency in which the
UpfrontPrice and HourlyPrice amounts are specified. |
Purchase |
withCurrencyCode(String currencyCode)
The currency in which the
UpfrontPrice and HourlyPrice amounts are specified. |
Purchase |
withDuration(Integer duration)
The duration of the reservation's term in seconds.
|
Purchase |
withHostIdSet(Collection<String> hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
|
Purchase |
withHostIdSet(String... hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
|
Purchase |
withHostReservationId(String hostReservationId)
The ID of the reservation.
|
Purchase |
withHourlyPrice(String hourlyPrice)
The hourly price of the reservation per hour.
|
Purchase |
withInstanceFamily(String instanceFamily)
The instance family on the Dedicated Host that the reservation can be associated with.
|
Purchase |
withPaymentOption(PaymentOption paymentOption)
The payment option for the reservation.
|
Purchase |
withPaymentOption(String paymentOption)
The payment option for the reservation.
|
Purchase |
withUpfrontPrice(String upfrontPrice)
The upfront price of the reservation.
|
public void setCurrencyCode(String currencyCode)
The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At this
time, the only supported currency is USD
.
currencyCode
- The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At
this time, the only supported currency is USD
.CurrencyCodeValues
public String getCurrencyCode()
The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At this
time, the only supported currency is USD
.
UpfrontPrice
and HourlyPrice
amounts are specified.
At this time, the only supported currency is USD
.CurrencyCodeValues
public Purchase withCurrencyCode(String currencyCode)
The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At this
time, the only supported currency is USD
.
currencyCode
- The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At
this time, the only supported currency is USD
.CurrencyCodeValues
public void setCurrencyCode(CurrencyCodeValues currencyCode)
The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At this
time, the only supported currency is USD
.
currencyCode
- The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At
this time, the only supported currency is USD
.CurrencyCodeValues
public Purchase withCurrencyCode(CurrencyCodeValues currencyCode)
The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At this
time, the only supported currency is USD
.
currencyCode
- The currency in which the UpfrontPrice
and HourlyPrice
amounts are specified. At
this time, the only supported currency is USD
.CurrencyCodeValues
public void setDuration(Integer duration)
The duration of the reservation's term in seconds.
duration
- The duration of the reservation's term in seconds.public Integer getDuration()
The duration of the reservation's term in seconds.
public Purchase withDuration(Integer duration)
The duration of the reservation's term in seconds.
duration
- The duration of the reservation's term in seconds.public List<String> getHostIdSet()
The IDs of the Dedicated Hosts associated with the reservation.
public void setHostIdSet(Collection<String> hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
hostIdSet
- The IDs of the Dedicated Hosts associated with the reservation.public Purchase withHostIdSet(String... hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
NOTE: This method appends the values to the existing list (if any). Use
setHostIdSet(java.util.Collection)
or withHostIdSet(java.util.Collection)
if you want to
override the existing values.
hostIdSet
- The IDs of the Dedicated Hosts associated with the reservation.public Purchase withHostIdSet(Collection<String> hostIdSet)
The IDs of the Dedicated Hosts associated with the reservation.
hostIdSet
- The IDs of the Dedicated Hosts associated with the reservation.public void setHostReservationId(String hostReservationId)
The ID of the reservation.
hostReservationId
- The ID of the reservation.public String getHostReservationId()
The ID of the reservation.
public Purchase withHostReservationId(String hostReservationId)
The ID of the reservation.
hostReservationId
- The ID of the reservation.public void setHourlyPrice(String hourlyPrice)
The hourly price of the reservation per hour.
hourlyPrice
- The hourly price of the reservation per hour.public String getHourlyPrice()
The hourly price of the reservation per hour.
public Purchase withHourlyPrice(String hourlyPrice)
The hourly price of the reservation per hour.
hourlyPrice
- The hourly price of the reservation per hour.public void setInstanceFamily(String instanceFamily)
The instance family on the Dedicated Host that the reservation can be associated with.
instanceFamily
- The instance family on the Dedicated Host that the reservation can be associated with.public String getInstanceFamily()
The instance family on the Dedicated Host that the reservation can be associated with.
public Purchase withInstanceFamily(String instanceFamily)
The instance family on the Dedicated Host that the reservation can be associated with.
instanceFamily
- The instance family on the Dedicated Host that the reservation can be associated with.public void setPaymentOption(String paymentOption)
The payment option for the reservation.
paymentOption
- The payment option for the reservation.PaymentOption
public String getPaymentOption()
The payment option for the reservation.
PaymentOption
public Purchase withPaymentOption(String paymentOption)
The payment option for the reservation.
paymentOption
- The payment option for the reservation.PaymentOption
public void setPaymentOption(PaymentOption paymentOption)
The payment option for the reservation.
paymentOption
- The payment option for the reservation.PaymentOption
public Purchase withPaymentOption(PaymentOption paymentOption)
The payment option for the reservation.
paymentOption
- The payment option for the reservation.PaymentOption
public void setUpfrontPrice(String upfrontPrice)
The upfront price of the reservation.
upfrontPrice
- The upfront price of the reservation.public String getUpfrontPrice()
The upfront price of the reservation.
public Purchase withUpfrontPrice(String upfrontPrice)
The upfront price of the reservation.
upfrontPrice
- The upfront price of the reservation.public String toString()
toString
in class Object
Object.toString()
Copyright © 2013 Amazon Web Services, Inc. All Rights Reserved.