@Generated(value="software.amazon.awssdk:codegen") public final class ModifyCapacityReservationRequest extends Ec2Request implements ToCopyableBuilder<ModifyCapacityReservationRequest.Builder,ModifyCapacityReservationRequest>
| Modifier and Type | Class and Description |
|---|---|
static interface |
ModifyCapacityReservationRequest.Builder |
| Modifier and Type | Method and Description |
|---|---|
static ModifyCapacityReservationRequest.Builder |
builder() |
String |
capacityReservationId()
The ID of the Capacity Reservation.
|
Instant |
endDate()
The date and time at which the Capacity Reservation expires.
|
EndDateType |
endDateType()
Indicates the way in which the Capacity Reservation ends.
|
String |
endDateTypeAsString()
Indicates the way in which the Capacity Reservation ends.
|
boolean |
equals(Object obj) |
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz)
Used to retrieve the value of a field from any class that extends
SdkRequest. |
int |
hashCode() |
Integer |
instanceCount()
The number of instances for which to reserve capacity.
|
List<SdkField<?>> |
sdkFields() |
static Class<? extends ModifyCapacityReservationRequest.Builder> |
serializableBuilderClass() |
ModifyCapacityReservationRequest.Builder |
toBuilder()
Take this object and create a builder that contains all of the current property values of this object.
|
String |
toString() |
overrideConfigurationcopypublic String capacityReservationId()
The ID of the Capacity Reservation.
public Integer instanceCount()
The number of instances for which to reserve capacity.
public Instant endDate()
The date and time at which the Capacity Reservation expires. When a Capacity Reservation expires, the reserved
capacity is released and you can no longer launch instances into it. The Capacity Reservation's state changes to
expired when it reaches its end date and time.
The Capacity Reservation is cancelled within an hour from the specified time. For example, if you specify 5/31/2019, 13:30:55, the Capacity Reservation is guaranteed to end between 13:30:55 and 14:30:55 on 5/31/2019.
You must provide an EndDate value if EndDateType is limited. Omit
EndDate if EndDateType is unlimited.
expired when it reaches its end date and time.
The Capacity Reservation is cancelled within an hour from the specified time. For example, if you specify 5/31/2019, 13:30:55, the Capacity Reservation is guaranteed to end between 13:30:55 and 14:30:55 on 5/31/2019.
You must provide an EndDate value if EndDateType is limited. Omit
EndDate if EndDateType is unlimited.
public EndDateType endDateType()
Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:
unlimited - The Capacity Reservation remains active until you explicitly cancel it. Do not provide
an EndDate value if EndDateType is unlimited.
limited - The Capacity Reservation expires automatically at a specified date and time. You must
provide an EndDate value if EndDateType is limited.
If the service returns an enum value that is not available in the current SDK version, endDateType will
return EndDateType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
endDateTypeAsString().
unlimited - The Capacity Reservation remains active until you explicitly cancel it. Do not
provide an EndDate value if EndDateType is unlimited.
limited - The Capacity Reservation expires automatically at a specified date and time. You
must provide an EndDate value if EndDateType is limited.
EndDateTypepublic String endDateTypeAsString()
Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:
unlimited - The Capacity Reservation remains active until you explicitly cancel it. Do not provide
an EndDate value if EndDateType is unlimited.
limited - The Capacity Reservation expires automatically at a specified date and time. You must
provide an EndDate value if EndDateType is limited.
If the service returns an enum value that is not available in the current SDK version, endDateType will
return EndDateType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
endDateTypeAsString().
unlimited - The Capacity Reservation remains active until you explicitly cancel it. Do not
provide an EndDate value if EndDateType is unlimited.
limited - The Capacity Reservation expires automatically at a specified date and time. You
must provide an EndDate value if EndDateType is limited.
EndDateTypepublic ModifyCapacityReservationRequest.Builder toBuilder()
ToCopyableBuildertoBuilder in interface ToCopyableBuilder<ModifyCapacityReservationRequest.Builder,ModifyCapacityReservationRequest>toBuilder in class Ec2Requestpublic static ModifyCapacityReservationRequest.Builder builder()
public static Class<? extends ModifyCapacityReservationRequest.Builder> serializableBuilderClass()
public <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
SdkRequestSdkRequest. The field name
specified should match the member name from the corresponding service-2.json model specified in the
codegen-resources folder for a given service. The class specifies what class to cast the returned value to.
If the returned value is also a modeled class, the SdkRequest.getValueForField(String, Class) method will
again be available.getValueForField in class SdkRequestfieldName - The name of the member to be retrieved.clazz - The class to cast the returned object to.Copyright © 2017 Amazon Web Services, Inc. All Rights Reserved.