Class CfnVolumeAttachment.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.CfnVolumeAttachment.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnVolumeAttachment>
- Enclosing class:
CfnVolumeAttachment
@Stability(Stable)
public static final class CfnVolumeAttachment.Builder
extends Object
implements software.amazon.jsii.Builder<CfnVolumeAttachment>
A fluent builder for
CfnVolumeAttachment
.-
Method Summary
Modifier and TypeMethodDescriptionbuild()
static CfnVolumeAttachment.Builder
The device name (for example,/dev/sdh
orxvdh
).instanceId
(String instanceId) The ID of the instance to which the volume attaches.The ID of the Amazon EBS volume.
-
Method Details
-
create
- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
- Returns:
- a new instance of
CfnVolumeAttachment.Builder
.
-
device
The device name (for example,/dev/sdh
orxvdh
).- Parameters:
device
- The device name (for example,/dev/sdh
orxvdh
). This parameter is required.- Returns:
this
-
instanceId
The ID of the instance to which the volume attaches.This value can be a reference to an
AWS::EC2::Instance
resource, or it can be the physical ID of an existing EC2 instance.- Parameters:
instanceId
- The ID of the instance to which the volume attaches. This parameter is required.- Returns:
this
-
volumeId
The ID of the Amazon EBS volume.The volume and instance must be within the same Availability Zone. This value can be a reference to an
AWS::EC2::Volume
resource, or it can be the volume ID of an existing Amazon EBS volume.- Parameters:
volumeId
- The ID of the Amazon EBS volume. This parameter is required.- Returns:
this
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnVolumeAttachment>
- Returns:
- a newly built instance of
CfnVolumeAttachment
.
-