com.amazonaws.services.ec2.model
Class ModifyInstanceAttributeRequest

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

public class ModifyInstanceAttributeRequest
extends AmazonWebServiceRequest

Container for the parameters to the ModifyInstanceAttribute operation.

Modifies an attribute of an instance.

See Also:
AmazonEC2.modifyInstanceAttribute(ModifyInstanceAttributeRequest)

Constructor Summary
ModifyInstanceAttributeRequest()
          Default constructor for a new ModifyInstanceAttributeRequest object.
ModifyInstanceAttributeRequest(String instanceId, String attribute)
          Constructs a new ModifyInstanceAttributeRequest object.
 
Method Summary
 String getAttribute()
          The name of the attribute being modified.
 List<InstanceBlockDeviceMappingSpecification> getBlockDeviceMappings()
          The new block device mappings for the instance whose attributes are being modified.
 String getInstanceId()
          The ID of the instance whose attribute is being modified.
 String getValue()
          The new value of the instance attribute being modified.
 void setAttribute(String attribute)
          The name of the attribute being modified.
 void setBlockDeviceMappings(Collection<InstanceBlockDeviceMappingSpecification> blockDeviceMappings)
          The new block device mappings for the instance whose attributes are being modified.
 void setInstanceId(String instanceId)
          The ID of the instance whose attribute is being modified.
 void setValue(String value)
          The new value of the instance attribute being modified.
 String toString()
          Returns a string representation of this object; useful for testing and debugging.
 ModifyInstanceAttributeRequest withAttribute(String attribute)
          The name of the attribute being modified.
 ModifyInstanceAttributeRequest withBlockDeviceMappings(Collection<InstanceBlockDeviceMappingSpecification> blockDeviceMappings)
          The new block device mappings for the instance whose attributes are being modified.
 ModifyInstanceAttributeRequest withBlockDeviceMappings(InstanceBlockDeviceMappingSpecification... blockDeviceMappings)
          The new block device mappings for the instance whose attributes are being modified.
 ModifyInstanceAttributeRequest withInstanceId(String instanceId)
          The ID of the instance whose attribute is being modified.
 ModifyInstanceAttributeRequest withValue(String value)
          The new value of the instance attribute being modified.
 
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyPrivateRequestParameters
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ModifyInstanceAttributeRequest

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


ModifyInstanceAttributeRequest

public ModifyInstanceAttributeRequest(String instanceId,
                                      String attribute)
Constructs a new ModifyInstanceAttributeRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.

Parameters:
instanceId - The ID of the instance whose attribute is being modified.
attribute - The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior

Method Detail

getInstanceId

public String getInstanceId()
The ID of the instance whose attribute is being modified.

Returns:
The ID of the instance whose attribute is being modified.

setInstanceId

public void setInstanceId(String instanceId)
The ID of the instance whose attribute is being modified.

Parameters:
instanceId - The ID of the instance whose attribute is being modified.

withInstanceId

public ModifyInstanceAttributeRequest withInstanceId(String instanceId)
The ID of the instance whose attribute is being modified.

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

Parameters:
instanceId - The ID of the instance whose attribute is being modified.
Returns:
A reference to this updated object so that method calls can be chained together.

getAttribute

public String getAttribute()
The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior

Returns:
The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior


setAttribute

public void setAttribute(String attribute)
The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior

Parameters:
attribute - The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior


withAttribute

public ModifyInstanceAttributeRequest withAttribute(String attribute)
The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior

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

Parameters:
attribute - The name of the attribute being modified.

Available attribute names: kernel, ramdisk, userData, blockDeviceMapping, disableApiTermination, instanceInitiatedShutdownBehavior

Returns:
A reference to this updated object so that method calls can be chained together.

getValue

public String getValue()
The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.

Returns:
The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.


setValue

public void setValue(String value)
The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.

Parameters:
value - The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.


withValue

public ModifyInstanceAttributeRequest withValue(String value)
The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.

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

Parameters:
value - The new value of the instance attribute being modified.

Only valid when kernel, ramdisk, userData disableApiTermination, or instanceInitiateShutdownBehavior is specified as the attribute being modified.

Returns:
A reference to this updated object so that method calls can be chained together.

getBlockDeviceMappings

public List<InstanceBlockDeviceMappingSpecification> getBlockDeviceMappings()
The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

Returns:
The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.


setBlockDeviceMappings

public void setBlockDeviceMappings(Collection<InstanceBlockDeviceMappingSpecification> blockDeviceMappings)
The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

Parameters:
blockDeviceMappings - The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.


withBlockDeviceMappings

public ModifyInstanceAttributeRequest withBlockDeviceMappings(InstanceBlockDeviceMappingSpecification... blockDeviceMappings)
The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

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

Parameters:
blockDeviceMappings - The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

Returns:
A reference to this updated object so that method calls can be chained together.

withBlockDeviceMappings

public ModifyInstanceAttributeRequest withBlockDeviceMappings(Collection<InstanceBlockDeviceMappingSpecification> blockDeviceMappings)
The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

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

Parameters:
blockDeviceMappings - The new block device mappings for the instance whose attributes are being modified.

Only valid when blockDeviceMapping is specified as the attribute being modified.

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()


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