com.amazonaws.services.ec2.model
Class InstanceAttribute

java.lang.Object
  extended by com.amazonaws.services.ec2.model.InstanceAttribute

public class InstanceAttribute
extends Object

Represents an attribute of an Amazon EC2 instance.


Constructor Summary
InstanceAttribute()
           
 
Method Summary
 boolean equals(Object obj)
           
 List<InstanceBlockDeviceMapping> getBlockDeviceMappings()
          How block devices are exposed to this instance.
 Boolean getDisableApiTermination()
          Whether this instance can be terminated.
 Boolean getEbsOptimized()
          Boolean value
 String getInstanceId()
          The ID of the associated instance.
 String getInstanceInitiatedShutdownBehavior()
          Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.
 String getInstanceType()
          The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).
 String getKernelId()
          The kernel ID of the associated instance.
 List<ProductCode> getProductCodes()
          Returns the value of the ProductCodes property for this object.
 String getRamdiskId()
          The ramdisk ID of the associated instance.
 String getRootDeviceName()
          The root device name (e.g., /dev/sda1).
 String getUserData()
          MIME, Base64-encoded user data.
 int hashCode()
           
 Boolean isDisableApiTermination()
          Whether this instance can be terminated.
 Boolean isEbsOptimized()
          Boolean value
 void setBlockDeviceMappings(Collection<InstanceBlockDeviceMapping> blockDeviceMappings)
          How block devices are exposed to this instance.
 void setDisableApiTermination(Boolean disableApiTermination)
          Whether this instance can be terminated.
 void setEbsOptimized(Boolean ebsOptimized)
          Boolean value
 void setInstanceId(String instanceId)
          The ID of the associated instance.
 void setInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior)
          Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.
 void setInstanceType(String instanceType)
          The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).
 void setKernelId(String kernelId)
          The kernel ID of the associated instance.
 void setProductCodes(Collection<ProductCode> productCodes)
          Sets the value of the ProductCodes property for this object.
 void setRamdiskId(String ramdiskId)
          The ramdisk ID of the associated instance.
 void setRootDeviceName(String rootDeviceName)
          The root device name (e.g., /dev/sda1).
 void setUserData(String userData)
          MIME, Base64-encoded user data.
 String toString()
          Returns a string representation of this object; useful for testing and debugging.
 InstanceAttribute withBlockDeviceMappings(Collection<InstanceBlockDeviceMapping> blockDeviceMappings)
          How block devices are exposed to this instance.
 InstanceAttribute withBlockDeviceMappings(InstanceBlockDeviceMapping... blockDeviceMappings)
          How block devices are exposed to this instance.
 InstanceAttribute withDisableApiTermination(Boolean disableApiTermination)
          Whether this instance can be terminated.
 InstanceAttribute withEbsOptimized(Boolean ebsOptimized)
          Boolean value
 InstanceAttribute withInstanceId(String instanceId)
          The ID of the associated instance.
 InstanceAttribute withInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior)
          Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.
 InstanceAttribute withInstanceType(String instanceType)
          The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).
 InstanceAttribute withKernelId(String kernelId)
          The kernel ID of the associated instance.
 InstanceAttribute withProductCodes(Collection<ProductCode> productCodes)
          Sets the value of the ProductCodes property for this object.
 InstanceAttribute withProductCodes(ProductCode... productCodes)
          Sets the value of the ProductCodes property for this object.
 InstanceAttribute withRamdiskId(String ramdiskId)
          The ramdisk ID of the associated instance.
 InstanceAttribute withRootDeviceName(String rootDeviceName)
          The root device name (e.g., /dev/sda1).
 InstanceAttribute withUserData(String userData)
          MIME, Base64-encoded user data.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InstanceAttribute

public InstanceAttribute()
Method Detail

getInstanceId

public String getInstanceId()
The ID of the associated instance.

Returns:
The ID of the associated instance.

setInstanceId

public void setInstanceId(String instanceId)
The ID of the associated instance.

Parameters:
instanceId - The ID of the associated instance.

withInstanceId

public InstanceAttribute withInstanceId(String instanceId)
The ID of the associated instance.

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

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

getInstanceType

public String getInstanceType()
The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).

Returns:
The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).

setInstanceType

public void setInstanceType(String instanceType)
The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).

Parameters:
instanceType - The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).

withInstanceType

public InstanceAttribute withInstanceType(String instanceType)
The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).

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

Parameters:
instanceType - The instance type (e.g., m1.small, c1.medium, m2.2xlarge, and so on).
Returns:
A reference to this updated object so that method calls can be chained together.

getKernelId

public String getKernelId()
The kernel ID of the associated instance.

Returns:
The kernel ID of the associated instance.

setKernelId

public void setKernelId(String kernelId)
The kernel ID of the associated instance.

Parameters:
kernelId - The kernel ID of the associated instance.

withKernelId

public InstanceAttribute withKernelId(String kernelId)
The kernel ID of the associated instance.

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

Parameters:
kernelId - The kernel ID of the associated instance.
Returns:
A reference to this updated object so that method calls can be chained together.

getRamdiskId

public String getRamdiskId()
The ramdisk ID of the associated instance.

Returns:
The ramdisk ID of the associated instance.

setRamdiskId

public void setRamdiskId(String ramdiskId)
The ramdisk ID of the associated instance.

Parameters:
ramdiskId - The ramdisk ID of the associated instance.

withRamdiskId

public InstanceAttribute withRamdiskId(String ramdiskId)
The ramdisk ID of the associated instance.

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

Parameters:
ramdiskId - The ramdisk ID of the associated instance.
Returns:
A reference to this updated object so that method calls can be chained together.

getUserData

public String getUserData()
MIME, Base64-encoded user data.

Returns:
MIME, Base64-encoded user data.

setUserData

public void setUserData(String userData)
MIME, Base64-encoded user data.

Parameters:
userData - MIME, Base64-encoded user data.

withUserData

public InstanceAttribute withUserData(String userData)
MIME, Base64-encoded user data.

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

Parameters:
userData - MIME, Base64-encoded user data.
Returns:
A reference to this updated object so that method calls can be chained together.

isDisableApiTermination

public Boolean isDisableApiTermination()
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

Returns:
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

setDisableApiTermination

public void setDisableApiTermination(Boolean disableApiTermination)
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

Parameters:
disableApiTermination - Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

withDisableApiTermination

public InstanceAttribute withDisableApiTermination(Boolean disableApiTermination)
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

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

Parameters:
disableApiTermination - Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.
Returns:
A reference to this updated object so that method calls can be chained together.

getDisableApiTermination

public Boolean getDisableApiTermination()
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

Returns:
Whether this instance can be terminated. You must modify this attribute before you can terminate any "locked" instances.

getInstanceInitiatedShutdownBehavior

public String getInstanceInitiatedShutdownBehavior()
Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.

Returns:
Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.

setInstanceInitiatedShutdownBehavior

public void setInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior)
Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.

Parameters:
instanceInitiatedShutdownBehavior - Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.

withInstanceInitiatedShutdownBehavior

public InstanceAttribute withInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior)
Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.

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

Parameters:
instanceInitiatedShutdownBehavior - Whether this instance's Amazon EBS volumes are deleted when the instance is shut down.
Returns:
A reference to this updated object so that method calls can be chained together.

getRootDeviceName

public String getRootDeviceName()
The root device name (e.g., /dev/sda1).

Returns:
The root device name (e.g., /dev/sda1).

setRootDeviceName

public void setRootDeviceName(String rootDeviceName)
The root device name (e.g., /dev/sda1).

Parameters:
rootDeviceName - The root device name (e.g., /dev/sda1).

withRootDeviceName

public InstanceAttribute withRootDeviceName(String rootDeviceName)
The root device name (e.g., /dev/sda1).

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

Parameters:
rootDeviceName - The root device name (e.g., /dev/sda1).
Returns:
A reference to this updated object so that method calls can be chained together.

getBlockDeviceMappings

public List<InstanceBlockDeviceMapping> getBlockDeviceMappings()
How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

Returns:
How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

setBlockDeviceMappings

public void setBlockDeviceMappings(Collection<InstanceBlockDeviceMapping> blockDeviceMappings)
How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

Parameters:
blockDeviceMappings - How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

withBlockDeviceMappings

public InstanceAttribute withBlockDeviceMappings(InstanceBlockDeviceMapping... blockDeviceMappings)
How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

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

Parameters:
blockDeviceMappings - How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.
Returns:
A reference to this updated object so that method calls can be chained together.

withBlockDeviceMappings

public InstanceAttribute withBlockDeviceMappings(Collection<InstanceBlockDeviceMapping> blockDeviceMappings)
How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.

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

Parameters:
blockDeviceMappings - How block devices are exposed to this instance. Each mapping is made up of a virtualName and a deviceName.
Returns:
A reference to this updated object so that method calls can be chained together.

getProductCodes

public List<ProductCode> getProductCodes()
Returns the value of the ProductCodes property for this object.

Returns:
The value of the ProductCodes property for this object.

setProductCodes

public void setProductCodes(Collection<ProductCode> productCodes)
Sets the value of the ProductCodes property for this object.

Parameters:
productCodes - The new value for the ProductCodes property for this object.

withProductCodes

public InstanceAttribute withProductCodes(ProductCode... productCodes)
Sets the value of the ProductCodes property for this object.

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

Parameters:
productCodes - The new value for the ProductCodes property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.

withProductCodes

public InstanceAttribute withProductCodes(Collection<ProductCode> productCodes)
Sets the value of the ProductCodes property for this object.

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

Parameters:
productCodes - The new value for the ProductCodes property for this object.
Returns:
A reference to this updated object so that method calls can be chained together.

isEbsOptimized

public Boolean isEbsOptimized()
Boolean value

Returns:
Boolean value

setEbsOptimized

public void setEbsOptimized(Boolean ebsOptimized)
Boolean value

Parameters:
ebsOptimized - Boolean value

withEbsOptimized

public InstanceAttribute withEbsOptimized(Boolean ebsOptimized)
Boolean value

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

Parameters:
ebsOptimized - Boolean value
Returns:
A reference to this updated object so that method calls can be chained together.

getEbsOptimized

public Boolean getEbsOptimized()
Boolean value

Returns:
Boolean value

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.