com.amazonaws.services.ec2.model
Class SpotInstanceRequest

java.lang.Object
  extended by com.amazonaws.services.ec2.model.SpotInstanceRequest
All Implemented Interfaces:
java.io.Serializable

public class SpotInstanceRequest
extends java.lang.Object
implements java.io.Serializable

Describe a Spot Instance request.

See Also:
Serialized Form

Constructor Summary
SpotInstanceRequest()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 java.lang.String getAvailabilityZoneGroup()
          The Availability Zone group.
 java.util.Date getCreateTime()
          The time stamp when the Spot Instance request was created.
 SpotInstanceStateFault getFault()
          The fault codes for the Spot Instance request, if any.
 java.lang.String getInstanceId()
          The instance ID, if an instance has been launched to fulfill the Spot Instance request.
 java.lang.String getLaunchedAvailabilityZone()
          The Availability Zone in which the bid is launched.
 java.lang.String getLaunchGroup()
          The instance launch group.
 LaunchSpecification getLaunchSpecification()
          Additional information for launching instances.
 java.lang.String getProductDescription()
          The product description associated with the Spot Instance.
 java.lang.String getSpotInstanceRequestId()
          The ID of the Spot Instance request.
 java.lang.String getSpotPrice()
          The maximum hourly price for any Spot Instance launched to fulfill the request.
 java.lang.String getState()
          The state of the Spot Instance request.
 SpotInstanceStatus getStatus()
          The status code and status message describing the Spot Instance request.
 java.util.List<Tag> getTags()
          Any tags assigned to the resource.
 java.lang.String getType()
          The Spot Instance request type.
 java.util.Date getValidFrom()
          The start date of the request.
 java.util.Date getValidUntil()
          The end date of the request.
 int hashCode()
           
 void setAvailabilityZoneGroup(java.lang.String availabilityZoneGroup)
          The Availability Zone group.
 void setCreateTime(java.util.Date createTime)
          The time stamp when the Spot Instance request was created.
 void setFault(SpotInstanceStateFault fault)
          The fault codes for the Spot Instance request, if any.
 void setInstanceId(java.lang.String instanceId)
          The instance ID, if an instance has been launched to fulfill the Spot Instance request.
 void setLaunchedAvailabilityZone(java.lang.String launchedAvailabilityZone)
          The Availability Zone in which the bid is launched.
 void setLaunchGroup(java.lang.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(java.lang.String productDescription)
          The product description associated with the Spot Instance.
 void setSpotInstanceRequestId(java.lang.String spotInstanceRequestId)
          The ID of the Spot Instance request.
 void setSpotPrice(java.lang.String spotPrice)
          The maximum hourly price for any Spot Instance launched to fulfill the request.
 void setState(SpotInstanceState state)
          The state of the Spot Instance request.
 void setState(java.lang.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(java.util.Collection<Tag> tags)
          Any tags assigned to the resource.
 void setType(SpotInstanceType type)
          The Spot Instance request type.
 void setType(java.lang.String type)
          The Spot Instance request type.
 void setValidFrom(java.util.Date validFrom)
          The start date of the request.
 void setValidUntil(java.util.Date validUntil)
          The end date of the request.
 java.lang.String toString()
          Returns a string representation of this object; useful for testing and debugging.
 SpotInstanceRequest withAvailabilityZoneGroup(java.lang.String availabilityZoneGroup)
          The Availability Zone group.
 SpotInstanceRequest withCreateTime(java.util.Date createTime)
          The time stamp when the Spot Instance request was created.
 SpotInstanceRequest withFault(SpotInstanceStateFault fault)
          The fault codes for the Spot Instance request, if any.
 SpotInstanceRequest withInstanceId(java.lang.String instanceId)
          The instance ID, if an instance has been launched to fulfill the Spot Instance request.
 SpotInstanceRequest withLaunchedAvailabilityZone(java.lang.String launchedAvailabilityZone)
          The Availability Zone in which the bid is launched.
 SpotInstanceRequest withLaunchGroup(java.lang.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(java.lang.String productDescription)
          The product description associated with the Spot Instance.
 SpotInstanceRequest withSpotInstanceRequestId(java.lang.String spotInstanceRequestId)
          The ID of the Spot Instance request.
 SpotInstanceRequest withSpotPrice(java.lang.String spotPrice)
          The maximum hourly price for any Spot Instance launched to fulfill the request.
 SpotInstanceRequest withState(SpotInstanceState state)
          The state of the Spot Instance request.
 SpotInstanceRequest withState(java.lang.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(java.util.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(java.lang.String type)
          The Spot Instance request type.
 SpotInstanceRequest withValidFrom(java.util.Date validFrom)
          The start date of the request.
 SpotInstanceRequest withValidUntil(java.util.Date validUntil)
          The end date of the request.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SpotInstanceRequest

public SpotInstanceRequest()
Method Detail

getSpotInstanceRequestId

public java.lang.String getSpotInstanceRequestId()
The ID of the Spot Instance request.

Returns:
The ID of the Spot Instance request.

setSpotInstanceRequestId

public void setSpotInstanceRequestId(java.lang.String spotInstanceRequestId)
The ID of the Spot Instance request.

Parameters:
spotInstanceRequestId - The ID of the Spot Instance request.

withSpotInstanceRequestId

public SpotInstanceRequest withSpotInstanceRequestId(java.lang.String spotInstanceRequestId)
The ID of the Spot Instance request.

Returns a reference to this object so that method calls can be chained together.

Parameters:
spotInstanceRequestId - The ID of the Spot Instance request.
Returns:
A reference to this updated object so that method calls can be chained together.

getSpotPrice

public java.lang.String getSpotPrice()
The maximum hourly price for any Spot Instance launched to fulfill the request.

Returns:
The maximum hourly price for any Spot Instance launched to fulfill the request.

setSpotPrice

public void setSpotPrice(java.lang.String spotPrice)
The maximum hourly price for any Spot Instance launched to fulfill the request.

Parameters:
spotPrice - The maximum hourly price for any Spot Instance launched to fulfill the request.

withSpotPrice

public SpotInstanceRequest withSpotPrice(java.lang.String spotPrice)
The maximum hourly price for any Spot Instance launched to fulfill the request.

Returns a reference to this object so that method calls can be chained together.

Parameters:
spotPrice - The maximum hourly price for any Spot Instance launched to fulfill the request.
Returns:
A reference to this updated object so that method calls can be chained together.

getType

public java.lang.String getType()
The Spot Instance request type.

Constraints:
Allowed Values: one-time, persistent

Returns:
The Spot Instance request type.
See Also:
SpotInstanceType

setType

public void setType(java.lang.String type)
The Spot Instance request type.

Constraints:
Allowed Values: one-time, persistent

Parameters:
type - The Spot Instance request type.
See Also:
SpotInstanceType

withType

public SpotInstanceRequest withType(java.lang.String type)
The Spot Instance request type.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: one-time, persistent

Parameters:
type - The Spot Instance request type.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
SpotInstanceType

setType

public void setType(SpotInstanceType type)
The Spot Instance request type.

Constraints:
Allowed Values: one-time, persistent

Parameters:
type - The Spot Instance request type.
See Also:
SpotInstanceType

withType

public SpotInstanceRequest withType(SpotInstanceType type)
The Spot Instance request type.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: one-time, persistent

Parameters:
type - The Spot Instance request type.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
SpotInstanceType

getState

public java.lang.String getState()
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.

Constraints:
Allowed Values: open, active, closed, cancelled, failed

Returns:
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.
See Also:
SpotInstanceState

setState

public void setState(java.lang.String state)
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.

Constraints:
Allowed Values: open, active, closed, cancelled, failed

Parameters:
state - The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.
See Also:
SpotInstanceState

withState

public SpotInstanceRequest withState(java.lang.String state)
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: open, active, closed, cancelled, failed

Parameters:
state - The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
SpotInstanceState

setState

public void setState(SpotInstanceState state)
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.

Constraints:
Allowed Values: open, active, closed, cancelled, failed

Parameters:
state - The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.
See Also:
SpotInstanceState

withState

public SpotInstanceRequest withState(SpotInstanceState state)
The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: open, active, closed, cancelled, failed

Parameters:
state - The state of the Spot Instance request. Spot bid status information can help you track your Spot Instance requests. For information, see Tracking Spot Requests with Bid Status Codes in the Amazon Elastic Compute Cloud User Guide.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
SpotInstanceState

getFault

public SpotInstanceStateFault getFault()
The fault codes for the Spot Instance request, if any.

Returns:
The fault codes for the Spot Instance request, if any.

setFault

public void setFault(SpotInstanceStateFault fault)
The fault codes for the Spot Instance request, if any.

Parameters:
fault - The fault codes for the Spot Instance request, if any.

withFault

public SpotInstanceRequest withFault(SpotInstanceStateFault fault)
The fault codes for the Spot Instance request, if any.

Returns a reference to this object so that method calls can be chained together.

Parameters:
fault - The fault codes for the Spot Instance request, if any.
Returns:
A reference to this updated object so that method calls can be chained together.

getStatus

public SpotInstanceStatus getStatus()
The status code and status message describing the Spot Instance request.

Returns:
The status code and status message describing the Spot Instance request.

setStatus

public void setStatus(SpotInstanceStatus status)
The status code and status message describing the Spot Instance request.

Parameters:
status - The status code and status message describing the Spot Instance request.

withStatus

public SpotInstanceRequest withStatus(SpotInstanceStatus status)
The status code and status message describing the Spot Instance request.

Returns a reference to this object so that method calls can be chained together.

Parameters:
status - The status code and status message describing the Spot Instance request.
Returns:
A reference to this updated object so that method calls can be chained together.

getValidFrom

public java.util.Date getValidFrom()
The start date of the request. 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.

Returns:
The start date of the request. 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.

setValidFrom

public void setValidFrom(java.util.Date validFrom)
The start date of the request. 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.

Parameters:
validFrom - The start date of the request. 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.

withValidFrom

public SpotInstanceRequest withValidFrom(java.util.Date validFrom)
The start date of the request. 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.

Returns a reference to this object so that method calls can be chained together.

Parameters:
validFrom - The start date of the request. 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.
Returns:
A reference to this updated object so that method calls can be chained together.

getValidUntil

public java.util.Date getValidUntil()
The end date of the request. 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.

Returns:
The end date of the request. 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.

setValidUntil

public void setValidUntil(java.util.Date validUntil)
The end date of the request. 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.

Parameters:
validUntil - The end date of the request. 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.

withValidUntil

public SpotInstanceRequest withValidUntil(java.util.Date validUntil)
The end date of the request. 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.

Returns a reference to this object so that method calls can be chained together.

Parameters:
validUntil - The end date of the request. 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.
Returns:
A reference to this updated object so that method calls can be chained together.

getLaunchGroup

public java.lang.String getLaunchGroup()
The instance launch group. Launch groups are Spot Instances that launch together and terminate together.

Returns:
The instance launch group. Launch groups are Spot Instances that launch together and terminate together.

setLaunchGroup

public void setLaunchGroup(java.lang.String launchGroup)
The instance launch group. Launch groups are Spot Instances that launch together and terminate together.

Parameters:
launchGroup - The instance launch group. Launch groups are Spot Instances that launch together and terminate together.

withLaunchGroup

public SpotInstanceRequest withLaunchGroup(java.lang.String launchGroup)
The instance launch group. Launch groups are Spot Instances that launch together and terminate together.

Returns a reference to this object so that method calls can be chained together.

Parameters:
launchGroup - The instance launch group. Launch groups are Spot Instances that launch together and terminate together.
Returns:
A reference to this updated object so that method calls can be chained together.

getAvailabilityZoneGroup

public java.lang.String getAvailabilityZoneGroup()
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.

Returns:
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.

setAvailabilityZoneGroup

public void setAvailabilityZoneGroup(java.lang.String 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.

Parameters:
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.

withAvailabilityZoneGroup

public SpotInstanceRequest withAvailabilityZoneGroup(java.lang.String 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.

Returns a reference to this object so that method calls can be chained together.

Parameters:
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.
Returns:
A reference to this updated object so that method calls can be chained together.

getLaunchSpecification

public LaunchSpecification getLaunchSpecification()
Additional information for launching instances.

Returns:
Additional information for launching instances.

setLaunchSpecification

public void setLaunchSpecification(LaunchSpecification launchSpecification)
Additional information for launching instances.

Parameters:
launchSpecification - Additional information for launching instances.

withLaunchSpecification

public SpotInstanceRequest withLaunchSpecification(LaunchSpecification launchSpecification)
Additional information for launching instances.

Returns a reference to this object so that method calls can be chained together.

Parameters:
launchSpecification - Additional information for launching instances.
Returns:
A reference to this updated object so that method calls can be chained together.

getInstanceId

public java.lang.String getInstanceId()
The instance ID, if an instance has been launched to fulfill the Spot Instance request.

Returns:
The instance ID, if an instance has been launched to fulfill the Spot Instance request.

setInstanceId

public void setInstanceId(java.lang.String instanceId)
The instance ID, if an instance has been launched to fulfill the Spot Instance request.

Parameters:
instanceId - The instance ID, if an instance has been launched to fulfill the Spot Instance request.

withInstanceId

public SpotInstanceRequest withInstanceId(java.lang.String instanceId)
The instance ID, if an instance has been launched to fulfill the Spot Instance request.

Returns a reference to this object so that method calls can be chained together.

Parameters:
instanceId - The instance ID, if an instance has been launched to fulfill the Spot Instance request.
Returns:
A reference to this updated object so that method calls can be chained together.

getCreateTime

public java.util.Date getCreateTime()
The time stamp when the Spot Instance request was created.

Returns:
The time stamp when the Spot Instance request was created.

setCreateTime

public void setCreateTime(java.util.Date createTime)
The time stamp when the Spot Instance request was created.

Parameters:
createTime - The time stamp when the Spot Instance request was created.

withCreateTime

public SpotInstanceRequest withCreateTime(java.util.Date createTime)
The time stamp when the Spot Instance request was created.

Returns a reference to this object so that method calls can be chained together.

Parameters:
createTime - The time stamp when the Spot Instance request was created.
Returns:
A reference to this updated object so that method calls can be chained together.

getProductDescription

public java.lang.String getProductDescription()
The product description associated with the Spot Instance.

Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)

Returns:
The product description associated with the Spot Instance.
See Also:
RIProductDescription

setProductDescription

public void setProductDescription(java.lang.String productDescription)
The product description associated with the Spot Instance.

Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)

Parameters:
productDescription - The product description associated with the Spot Instance.
See Also:
RIProductDescription

withProductDescription

public SpotInstanceRequest withProductDescription(java.lang.String productDescription)
The product description associated with the Spot Instance.

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)

Parameters:
productDescription - The product description associated with the Spot Instance.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
RIProductDescription

setProductDescription

public void setProductDescription(RIProductDescription productDescription)
The product description associated with the Spot Instance.

Constraints:
Allowed Values: Linux/UNIX, Linux/UNIX (Amazon VPC), Windows, Windows (Amazon VPC)

Parameters:
productDescription - The product description associated with the Spot Instance.
See Also:
RIProductDescription

withProductDescription

public SpotInstanceRequest withProductDescription(RIProductDescription productDescription)
The product description associated with the Spot Instance.

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)

Parameters:
productDescription - The product description associated with the Spot Instance.
Returns:
A reference to this updated object so that method calls can be chained together.
See Also:
RIProductDescription

getTags

public java.util.List<Tag> getTags()
Any tags assigned to the resource.

Returns:
Any tags assigned to the resource.

setTags

public void setTags(java.util.Collection<Tag> tags)
Any tags assigned to the resource.

Parameters:
tags - Any tags assigned to the resource.

withTags

public SpotInstanceRequest withTags(Tag... tags)
Any tags assigned to the resource.

Returns a reference to this object so that method calls can be chained together.

Parameters:
tags - Any tags assigned to the resource.
Returns:
A reference to this updated object so that method calls can be chained together.

withTags

public SpotInstanceRequest withTags(java.util.Collection<Tag> tags)
Any tags assigned to the resource.

Returns a reference to this object so that method calls can be chained together.

Parameters:
tags - Any tags assigned to the resource.
Returns:
A reference to this updated object so that method calls can be chained together.

getLaunchedAvailabilityZone

public java.lang.String getLaunchedAvailabilityZone()
The Availability Zone in which the bid is launched.

Returns:
The Availability Zone in which the bid is launched.

setLaunchedAvailabilityZone

public void setLaunchedAvailabilityZone(java.lang.String launchedAvailabilityZone)
The Availability Zone in which the bid is launched.

Parameters:
launchedAvailabilityZone - The Availability Zone in which the bid is launched.

withLaunchedAvailabilityZone

public SpotInstanceRequest withLaunchedAvailabilityZone(java.lang.String launchedAvailabilityZone)
The Availability Zone in which the bid is launched.

Returns a reference to this object so that method calls can be chained together.

Parameters:
launchedAvailabilityZone - The Availability Zone in which the bid is launched.
Returns:
A reference to this updated object so that method calls can be chained together.

toString

public java.lang.String toString()
Returns a string representation of this object; useful for testing and debugging.

Overrides:
toString in class java.lang.Object
Returns:
A string representation of this object.
See Also:
Object.toString()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2010 Amazon Web Services, Inc. All Rights Reserved.