com.amazonaws.services.ec2.model
Class TerminateInstancesRequest

java.lang.Object
  extended by com.amazonaws.AmazonWebServiceRequest
      extended by com.amazonaws.services.ec2.model.TerminateInstancesRequest

public class TerminateInstancesRequest
extends AmazonWebServiceRequest

Container for the parameters to the TerminateInstances operation.

The TerminateInstances operation shuts down one or more instances. This operation is idempotent; if you terminate an instance more than once, each call will succeed.

Terminated instances will remain visible after termination (approximately one hour).

See Also:
AmazonEC2.terminateInstances(TerminateInstancesRequest)

Constructor Summary
TerminateInstancesRequest()
          Default constructor for a new TerminateInstancesRequest object.
TerminateInstancesRequest(List<String> instanceIds)
          Constructs a new TerminateInstancesRequest object.
 
Method Summary
 boolean equals(Object obj)
           
 List<String> getInstanceIds()
          The list of instances to terminate.
 int hashCode()
           
 void setInstanceIds(Collection<String> instanceIds)
          The list of instances to terminate.
 String toString()
          Returns a string representation of this object; useful for testing and debugging.
 TerminateInstancesRequest withInstanceIds(Collection<String> instanceIds)
          The list of instances to terminate.
 TerminateInstancesRequest withInstanceIds(String... instanceIds)
          The list of instances to terminate.
 
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyPrivateRequestParameters, getDelegationToken, getRequestClientOptions, getRequestCredentials, setDelegationToken, setRequestCredentials
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TerminateInstancesRequest

public TerminateInstancesRequest()
Default constructor for a new TerminateInstancesRequest object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.


TerminateInstancesRequest

public TerminateInstancesRequest(List<String> instanceIds)
Constructs a new TerminateInstancesRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.

Parameters:
instanceIds - The list of instances to terminate.
Method Detail

getInstanceIds

public List<String> getInstanceIds()
The list of instances to terminate.

Returns:
The list of instances to terminate.

setInstanceIds

public void setInstanceIds(Collection<String> instanceIds)
The list of instances to terminate.

Parameters:
instanceIds - The list of instances to terminate.

withInstanceIds

public TerminateInstancesRequest withInstanceIds(String... instanceIds)
The list of instances to terminate.

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

Parameters:
instanceIds - The list of instances to terminate.
Returns:
A reference to this updated object so that method calls can be chained together.

withInstanceIds

public TerminateInstancesRequest withInstanceIds(Collection<String> instanceIds)
The list of instances to terminate.

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

Parameters:
instanceIds - The list of instances to terminate.
Returns:
A reference to this updated object so that method calls can be chained together.

toString

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

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

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object


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