Class CfnNetworkInterfaceAttachment.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.CfnNetworkInterfaceAttachment.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnNetworkInterfaceAttachment>
- Enclosing class:
CfnNetworkInterfaceAttachment
@Stability(Stable)
public static final class CfnNetworkInterfaceAttachment.Builder
extends Object
implements software.amazon.jsii.Builder<CfnNetworkInterfaceAttachment>
A fluent builder for
CfnNetworkInterfaceAttachment
.-
Method Summary
Modifier and TypeMethodDescriptionbuild()
deleteOnTermination
(Boolean deleteOnTermination) Whether to delete the network interface when the instance terminates.deleteOnTermination
(IResolvable deleteOnTermination) Whether to delete the network interface when the instance terminates.deviceIndex
(String deviceIndex) The network interface's position in the attachment order.enaSrdSpecification
(IResolvable enaSrdSpecification) Configures ENA Express for the network interface that this action attaches to the instance.enaSrdSpecification
(CfnNetworkInterfaceAttachment.EnaSrdSpecificationProperty enaSrdSpecification) Configures ENA Express for the network interface that this action attaches to the instance.instanceId
(String instanceId) The ID of the instance to which you will attach the ENI.networkInterfaceId
(String networkInterfaceId) The ID of the ENI that you want to attach.
-
Method Details
-
create
@Stability(Stable) public static CfnNetworkInterfaceAttachment.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.- Returns:
- a new instance of
CfnNetworkInterfaceAttachment.Builder
.
-
deviceIndex
The network interface's position in the attachment order.For example, the first attached network interface has a
DeviceIndex
of 0.- Parameters:
deviceIndex
- The network interface's position in the attachment order. This parameter is required.- Returns:
this
- See Also:
-
instanceId
The ID of the instance to which you will attach the ENI.- Parameters:
instanceId
- The ID of the instance to which you will attach the ENI. This parameter is required.- Returns:
this
- See Also:
-
networkInterfaceId
@Stability(Stable) public CfnNetworkInterfaceAttachment.Builder networkInterfaceId(String networkInterfaceId) The ID of the ENI that you want to attach.- Parameters:
networkInterfaceId
- The ID of the ENI that you want to attach. This parameter is required.- Returns:
this
- See Also:
-
deleteOnTermination
@Stability(Stable) public CfnNetworkInterfaceAttachment.Builder deleteOnTermination(Boolean deleteOnTermination) Whether to delete the network interface when the instance terminates.By default, this value is set to
true
.Default: - true
- Parameters:
deleteOnTermination
- Whether to delete the network interface when the instance terminates. This parameter is required.- Returns:
this
- See Also:
-
deleteOnTermination
@Stability(Stable) public CfnNetworkInterfaceAttachment.Builder deleteOnTermination(IResolvable deleteOnTermination) Whether to delete the network interface when the instance terminates.By default, this value is set to
true
.Default: - true
- Parameters:
deleteOnTermination
- Whether to delete the network interface when the instance terminates. This parameter is required.- Returns:
this
- See Also:
-
enaSrdSpecification
@Stability(Stable) public CfnNetworkInterfaceAttachment.Builder enaSrdSpecification(IResolvable enaSrdSpecification) Configures ENA Express for the network interface that this action attaches to the instance.- Parameters:
enaSrdSpecification
- Configures ENA Express for the network interface that this action attaches to the instance. This parameter is required.- Returns:
this
- See Also:
-
enaSrdSpecification
@Stability(Stable) public CfnNetworkInterfaceAttachment.Builder enaSrdSpecification(CfnNetworkInterfaceAttachment.EnaSrdSpecificationProperty enaSrdSpecification) Configures ENA Express for the network interface that this action attaches to the instance.- Parameters:
enaSrdSpecification
- Configures ENA Express for the network interface that this action attaches to the instance. This parameter is required.- Returns:
this
- See Also:
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnNetworkInterfaceAttachment>
- Returns:
- a newly built instance of
CfnNetworkInterfaceAttachment
.
-