public class SpotInstanceRequest extends Object implements Serializable, Cloneable
Describe a Spot instance request.
Constructor and Description |
---|
SpotInstanceRequest() |
Modifier and Type | Method and Description |
---|---|
SpotInstanceRequest |
clone() |
boolean |
equals(Object obj) |
String |
getAvailabilityZoneGroup()
The Availability Zone group.
|
Date |
getCreateTime()
The date and time when the Spot instance request was created, in UTC
format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
SpotInstanceStateFault |
getFault()
The fault codes for the Spot instance request, if any.
|
String |
getInstanceId()
The instance ID, if an instance has been launched to fulfill the Spot
instance request.
|
String |
getLaunchedAvailabilityZone()
The Availability Zone in which the bid is launched.
|
String |
getLaunchGroup()
The instance launch group.
|
LaunchSpecification |
getLaunchSpecification()
Additional information for launching instances.
|
String |
getProductDescription()
The product description associated with the Spot instance.
|
String |
getSpotInstanceRequestId()
The ID of the Spot instance request.
|
String |
getSpotPrice()
The maximum hourly price (bid) for any Spot instance launched to
fulfill the request.
|
String |
getState()
The state of the Spot instance request.
|
SpotInstanceStatus |
getStatus()
The status code and status message describing the Spot instance
request.
|
List<Tag> |
getTags()
Any tags assigned to the resource.
|
String |
getType()
The Spot instance request type.
|
Date |
getValidFrom()
The start date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
Date |
getValidUntil()
The end date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
int |
hashCode() |
void |
setAvailabilityZoneGroup(String availabilityZoneGroup)
The Availability Zone group.
|
void |
setCreateTime(Date createTime)
The date and time when the Spot instance request was created, in UTC
format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
void |
setFault(SpotInstanceStateFault fault)
The fault codes for the Spot instance request, if any.
|
void |
setInstanceId(String instanceId)
The instance ID, if an instance has been launched to fulfill the Spot
instance request.
|
void |
setLaunchedAvailabilityZone(String launchedAvailabilityZone)
The Availability Zone in which the bid is launched.
|
void |
setLaunchGroup(String launchGroup)
The instance launch group.
|
void |
setLaunchSpecification(LaunchSpecification launchSpecification)
Additional information for launching instances.
|
void |
setProductDescription(RIProductDescription productDescription)
The product description associated with the Spot instance.
|
void |
setProductDescription(String productDescription)
The product description associated with the Spot instance.
|
void |
setSpotInstanceRequestId(String spotInstanceRequestId)
The ID of the Spot instance request.
|
void |
setSpotPrice(String spotPrice)
The maximum hourly price (bid) for any Spot instance launched to
fulfill the request.
|
void |
setState(SpotInstanceState state)
The state of the Spot instance request.
|
void |
setState(String state)
The state of the Spot instance request.
|
void |
setStatus(SpotInstanceStatus status)
The status code and status message describing the Spot instance
request.
|
void |
setTags(Collection<Tag> tags)
Any tags assigned to the resource.
|
void |
setType(SpotInstanceType type)
The Spot instance request type.
|
void |
setType(String type)
The Spot instance request type.
|
void |
setValidFrom(Date validFrom)
The start date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
void |
setValidUntil(Date validUntil)
The end date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
SpotInstanceRequest |
withAvailabilityZoneGroup(String availabilityZoneGroup)
The Availability Zone group.
|
SpotInstanceRequest |
withCreateTime(Date createTime)
The date and time when the Spot instance request was created, in UTC
format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
SpotInstanceRequest |
withFault(SpotInstanceStateFault fault)
The fault codes for the Spot instance request, if any.
|
SpotInstanceRequest |
withInstanceId(String instanceId)
The instance ID, if an instance has been launched to fulfill the Spot
instance request.
|
SpotInstanceRequest |
withLaunchedAvailabilityZone(String launchedAvailabilityZone)
The Availability Zone in which the bid is launched.
|
SpotInstanceRequest |
withLaunchGroup(String launchGroup)
The instance launch group.
|
SpotInstanceRequest |
withLaunchSpecification(LaunchSpecification launchSpecification)
Additional information for launching instances.
|
SpotInstanceRequest |
withProductDescription(RIProductDescription productDescription)
The product description associated with the Spot instance.
|
SpotInstanceRequest |
withProductDescription(String productDescription)
The product description associated with the Spot instance.
|
SpotInstanceRequest |
withSpotInstanceRequestId(String spotInstanceRequestId)
The ID of the Spot instance request.
|
SpotInstanceRequest |
withSpotPrice(String spotPrice)
The maximum hourly price (bid) for any Spot instance launched to
fulfill the request.
|
SpotInstanceRequest |
withState(SpotInstanceState state)
The state of the Spot instance request.
|
SpotInstanceRequest |
withState(String state)
The state of the Spot instance request.
|
SpotInstanceRequest |
withStatus(SpotInstanceStatus status)
The status code and status message describing the Spot instance
request.
|
SpotInstanceRequest |
withTags(Collection<Tag> tags)
Any tags assigned to the resource.
|
SpotInstanceRequest |
withTags(Tag... tags)
Any tags assigned to the resource.
|
SpotInstanceRequest |
withType(SpotInstanceType type)
The Spot instance request type.
|
SpotInstanceRequest |
withType(String type)
The Spot instance request type.
|
SpotInstanceRequest |
withValidFrom(Date validFrom)
The start date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
SpotInstanceRequest |
withValidUntil(Date validUntil)
The end date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ).
|
public String getSpotInstanceRequestId()
public void setSpotInstanceRequestId(String spotInstanceRequestId)
spotInstanceRequestId
- The ID of the Spot instance request.public SpotInstanceRequest withSpotInstanceRequestId(String spotInstanceRequestId)
Returns a reference to this object so that method calls can be chained together.
spotInstanceRequestId
- The ID of the Spot instance request.public String getSpotPrice()
public void setSpotPrice(String spotPrice)
spotPrice
- The maximum hourly price (bid) for any Spot instance launched to
fulfill the request.public SpotInstanceRequest withSpotPrice(String spotPrice)
Returns a reference to this object so that method calls can be chained together.
spotPrice
- The maximum hourly price (bid) for any Spot instance launched to
fulfill the request.public String getType()
Constraints:
Allowed Values: one-time, persistent
SpotInstanceType
public void setType(String type)
Constraints:
Allowed Values: one-time, persistent
type
- The Spot instance request type.SpotInstanceType
public SpotInstanceRequest withType(String type)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: one-time, persistent
type
- The Spot instance request type.SpotInstanceType
public void setType(SpotInstanceType type)
Constraints:
Allowed Values: one-time, persistent
type
- The Spot instance request type.SpotInstanceType
public SpotInstanceRequest withType(SpotInstanceType type)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: one-time, persistent
type
- The Spot instance request type.SpotInstanceType
public String getState()
Constraints:
Allowed Values: open, active, closed, cancelled, failed
SpotInstanceState
public void setState(String state)
Constraints:
Allowed Values: open, active, closed, cancelled, failed
state
- The state of the Spot instance request. Spot bid status information
can help you track your Spot instance requests. For more information,
see Spot
Bid Status in the Amazon Elastic Compute Cloud User Guide.SpotInstanceState
public SpotInstanceRequest withState(String state)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: open, active, closed, cancelled, failed
state
- The state of the Spot instance request. Spot bid status information
can help you track your Spot instance requests. For more information,
see Spot
Bid Status in the Amazon Elastic Compute Cloud User Guide.SpotInstanceState
public void setState(SpotInstanceState state)
Constraints:
Allowed Values: open, active, closed, cancelled, failed
state
- The state of the Spot instance request. Spot bid status information
can help you track your Spot instance requests. For more information,
see Spot
Bid Status in the Amazon Elastic Compute Cloud User Guide.SpotInstanceState
public SpotInstanceRequest withState(SpotInstanceState state)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: open, active, closed, cancelled, failed
state
- The state of the Spot instance request. Spot bid status information
can help you track your Spot instance requests. For more information,
see Spot
Bid Status in the Amazon Elastic Compute Cloud User Guide.SpotInstanceState
public SpotInstanceStateFault getFault()
public void setFault(SpotInstanceStateFault fault)
fault
- The fault codes for the Spot instance request, if any.public SpotInstanceRequest withFault(SpotInstanceStateFault fault)
Returns a reference to this object so that method calls can be chained together.
fault
- The fault codes for the Spot instance request, if any.public SpotInstanceStatus getStatus()
public void setStatus(SpotInstanceStatus status)
status
- The status code and status message describing the Spot instance
request.public SpotInstanceRequest withStatus(SpotInstanceStatus status)
Returns a reference to this object so that method calls can be chained together.
status
- The status code and status message describing the Spot instance
request.public Date getValidFrom()
public void setValidFrom(Date validFrom)
validFrom
- The start date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ). If
this is a one-time request, the request becomes active at this date
and time and remains active until all instances launch, the request
expires, or the request is canceled. If the request is persistent, the
request becomes active at this date and time and remains active until
it expires or is canceled.public SpotInstanceRequest withValidFrom(Date validFrom)
Returns a reference to this object so that method calls can be chained together.
validFrom
- The start date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ). If
this is a one-time request, the request becomes active at this date
and time and remains active until all instances launch, the request
expires, or the request is canceled. If the request is persistent, the
request becomes active at this date and time and remains active until
it expires or is canceled.public Date getValidUntil()
public void setValidUntil(Date validUntil)
validUntil
- The end date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ). If
this is a one-time request, the request remains active until all
instances launch, the request is canceled, or this date is reached. If
the request is persistent, it remains active until it is canceled or
this date is reached.public SpotInstanceRequest withValidUntil(Date validUntil)
Returns a reference to this object so that method calls can be chained together.
validUntil
- The end date of the request, in UTC format (for example,
YYYY-MM-DDTHH:MM:SSZ). If
this is a one-time request, the request remains active until all
instances launch, the request is canceled, or this date is reached. If
the request is persistent, it remains active until it is canceled or
this date is reached.public String getLaunchGroup()
public void setLaunchGroup(String launchGroup)
launchGroup
- The instance launch group. Launch groups are Spot instances that
launch together and terminate together.public SpotInstanceRequest withLaunchGroup(String launchGroup)
Returns a reference to this object so that method calls can be chained together.
launchGroup
- The instance launch group. Launch groups are Spot instances that
launch together and terminate together.public String getAvailabilityZoneGroup()
public void setAvailabilityZoneGroup(String availabilityZoneGroup)
availabilityZoneGroup
- The Availability Zone group. If you specify the same Availability Zone
group for all Spot instance requests, all Spot instances are launched
in the same Availability Zone.public SpotInstanceRequest withAvailabilityZoneGroup(String availabilityZoneGroup)
Returns a reference to this object so that method calls can be chained together.
availabilityZoneGroup
- The Availability Zone group. If you specify the same Availability Zone
group for all Spot instance requests, all Spot instances are launched
in the same Availability Zone.public LaunchSpecification getLaunchSpecification()
public void setLaunchSpecification(LaunchSpecification launchSpecification)
launchSpecification
- Additional information for launching instances.public SpotInstanceRequest withLaunchSpecification(LaunchSpecification launchSpecification)
Returns a reference to this object so that method calls can be chained together.
launchSpecification
- Additional information for launching instances.public String getInstanceId()
public void setInstanceId(String instanceId)
instanceId
- The instance ID, if an instance has been launched to fulfill the Spot
instance request.public SpotInstanceRequest withInstanceId(String instanceId)
Returns a reference to this object so that method calls can be chained together.
instanceId
- The instance ID, if an instance has been launched to fulfill the Spot
instance request.public Date getCreateTime()
public void setCreateTime(Date createTime)
createTime
- The date and time when the Spot instance request was created, in UTC
format (for example,
YYYY-MM-DDTHH:MM:SSZ).public SpotInstanceRequest withCreateTime(Date createTime)
Returns a reference to this object so that method calls can be chained together.
createTime
- The date and time when the Spot instance request was created, in UTC
format (for example,
YYYY-MM-DDTHH:MM:SSZ).public String getProductDescription()
Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)
RIProductDescription
public void setProductDescription(String productDescription)
Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)
productDescription
- The product description associated with the Spot instance.RIProductDescription
public SpotInstanceRequest withProductDescription(String productDescription)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)
productDescription
- The product description associated with the Spot instance.RIProductDescription
public void setProductDescription(RIProductDescription productDescription)
Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)
productDescription
- The product description associated with the Spot instance.RIProductDescription
public SpotInstanceRequest withProductDescription(RIProductDescription productDescription)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)
productDescription
- The product description associated with the Spot instance.RIProductDescription
public List<Tag> getTags()
public void setTags(Collection<Tag> tags)
tags
- Any tags assigned to the resource.public SpotInstanceRequest withTags(Tag... tags)
NOTE: This method appends the values to the existing list (if
any). Use setTags(java.util.Collection)
or withTags(java.util.Collection)
if you want to override the existing
values.
Returns a reference to this object so that method calls can be chained together.
tags
- Any tags assigned to the resource.public SpotInstanceRequest withTags(Collection<Tag> tags)
Returns a reference to this object so that method calls can be chained together.
tags
- Any tags assigned to the resource.public String getLaunchedAvailabilityZone()
public void setLaunchedAvailabilityZone(String launchedAvailabilityZone)
launchedAvailabilityZone
- The Availability Zone in which the bid is launched.public SpotInstanceRequest withLaunchedAvailabilityZone(String launchedAvailabilityZone)
Returns a reference to this object so that method calls can be chained together.
launchedAvailabilityZone
- The Availability Zone in which the bid is launched.public String toString()
toString
in class Object
Object.toString()
public SpotInstanceRequest clone()
Copyright © 2015. All rights reserved.