Class BlockDeviceMapping
- java.lang.Object
-
- com.amazonaws.services.ec2.model.BlockDeviceMapping
-
- All Implemented Interfaces:
Serializable,Cloneable
public class BlockDeviceMapping extends Object implements Serializable, Cloneable
Describes a block device mapping.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BlockDeviceMapping()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BlockDeviceMappingclone()booleanequals(Object obj)StringgetDeviceName()The device name exposed to the instance (for example,/dev/sdhorxvdh).EbsBlockDevicegetEbs()Parameters used to automatically set up EBS volumes when the instance is launched.StringgetNoDevice()Suppresses the specified device included in the block device mapping of the AMI.StringgetVirtualName()The virtual device name (ephemeralN).inthashCode()voidsetDeviceName(String deviceName)The device name exposed to the instance (for example,/dev/sdhorxvdh).voidsetEbs(EbsBlockDevice ebs)Parameters used to automatically set up EBS volumes when the instance is launched.voidsetNoDevice(String noDevice)Suppresses the specified device included in the block device mapping of the AMI.voidsetVirtualName(String virtualName)The virtual device name (ephemeralN).StringtoString()Returns a string representation of this object; useful for testing and debugging.BlockDeviceMappingwithDeviceName(String deviceName)The device name exposed to the instance (for example,/dev/sdhorxvdh).BlockDeviceMappingwithEbs(EbsBlockDevice ebs)Parameters used to automatically set up EBS volumes when the instance is launched.BlockDeviceMappingwithNoDevice(String noDevice)Suppresses the specified device included in the block device mapping of the AMI.BlockDeviceMappingwithVirtualName(String virtualName)The virtual device name (ephemeralN).
-
-
-
Method Detail
-
setVirtualName
public void setVirtualName(String virtualName)
The virtual device name (
ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
- Parameters:
virtualName- The virtual device name (ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
-
getVirtualName
public String getVirtualName()
The virtual device name (
ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
- Returns:
- The virtual device name (
ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
-
withVirtualName
public BlockDeviceMapping withVirtualName(String virtualName)
The virtual device name (
ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
- Parameters:
virtualName- The virtual device name (ephemeralN). Instance store volumes are numbered starting from 0. An instance type with 2 available instance store volumes can specify mappings forephemeral0andephemeral1.The number of available instance store volumes depends on the instance type. After you connect to the instance, you must mount the volume.Constraints: For M3 instances, you must specify instance store volumes in the block device mapping for the instance. When you launch an M3 instance, we ignore any instance store volumes specified in the block device mapping for the AMI.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setDeviceName
public void setDeviceName(String deviceName)
The device name exposed to the instance (for example,
/dev/sdhorxvdh).- Parameters:
deviceName- The device name exposed to the instance (for example,/dev/sdhorxvdh).
-
getDeviceName
public String getDeviceName()
The device name exposed to the instance (for example,
/dev/sdhorxvdh).- Returns:
- The device name exposed to the instance (for example,
/dev/sdhorxvdh).
-
withDeviceName
public BlockDeviceMapping withDeviceName(String deviceName)
The device name exposed to the instance (for example,
/dev/sdhorxvdh).- Parameters:
deviceName- The device name exposed to the instance (for example,/dev/sdhorxvdh).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setEbs
public void setEbs(EbsBlockDevice ebs)
Parameters used to automatically set up EBS volumes when the instance is launched.
- Parameters:
ebs- Parameters used to automatically set up EBS volumes when the instance is launched.
-
getEbs
public EbsBlockDevice getEbs()
Parameters used to automatically set up EBS volumes when the instance is launched.
- Returns:
- Parameters used to automatically set up EBS volumes when the instance is launched.
-
withEbs
public BlockDeviceMapping withEbs(EbsBlockDevice ebs)
Parameters used to automatically set up EBS volumes when the instance is launched.
- Parameters:
ebs- Parameters used to automatically set up EBS volumes when the instance is launched.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setNoDevice
public void setNoDevice(String noDevice)
Suppresses the specified device included in the block device mapping of the AMI.
- Parameters:
noDevice- Suppresses the specified device included in the block device mapping of the AMI.
-
getNoDevice
public String getNoDevice()
Suppresses the specified device included in the block device mapping of the AMI.
- Returns:
- Suppresses the specified device included in the block device mapping of the AMI.
-
withNoDevice
public BlockDeviceMapping withNoDevice(String noDevice)
Suppresses the specified device included in the block device mapping of the AMI.
- Parameters:
noDevice- Suppresses the specified device included in the block device mapping of the AMI.- Returns:
- Returns a reference to this 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:
toStringin classObject- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public BlockDeviceMapping clone()
-
-