Class CfnNetworkInterfaceMixinProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnNetworkInterfaceMixinProps>
- Enclosing interface:
CfnNetworkInterfaceMixinProps
CfnNetworkInterfaceMixinProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.connectionTrackingSpecification(CfnNetworkInterfacePropsMixin.ConnectionTrackingSpecificationProperty connectionTrackingSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getConnectionTrackingSpecification()connectionTrackingSpecification(IResolvable connectionTrackingSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getConnectionTrackingSpecification()description(String description) Sets the value ofCfnNetworkInterfaceMixinProps.getDescription()enablePrimaryIpv6(Boolean enablePrimaryIpv6) Sets the value ofCfnNetworkInterfaceMixinProps.getEnablePrimaryIpv6()enablePrimaryIpv6(IResolvable enablePrimaryIpv6) Sets the value ofCfnNetworkInterfaceMixinProps.getEnablePrimaryIpv6()Sets the value ofCfnNetworkInterfaceMixinProps.getGroupSet()interfaceType(String interfaceType) Sets the value ofCfnNetworkInterfaceMixinProps.getInterfaceType()ipv4PrefixCount(Number ipv4PrefixCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4PrefixCount()ipv4Prefixes(List<? extends Object> ipv4Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4Prefixes()ipv4Prefixes(IResolvable ipv4Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4Prefixes()ipv6AddressCount(Number ipv6AddressCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6AddressCount()ipv6Addresses(List<? extends Object> ipv6Addresses) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Addresses()ipv6Addresses(IResolvable ipv6Addresses) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Addresses()ipv6PrefixCount(Number ipv6PrefixCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6PrefixCount()ipv6Prefixes(List<? extends Object> ipv6Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Prefixes()ipv6Prefixes(IResolvable ipv6Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Prefixes()privateIpAddress(String privateIpAddress) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddress()privateIpAddresses(List<? extends Object> privateIpAddresses) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddresses()privateIpAddresses(IResolvable privateIpAddresses) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddresses()publicIpDnsHostnameTypeSpecification(String publicIpDnsHostnameTypeSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getPublicIpDnsHostnameTypeSpecification()secondaryPrivateIpAddressCount(Number secondaryPrivateIpAddressCount) Sets the value ofCfnNetworkInterfaceMixinProps.getSecondaryPrivateIpAddressCount()sourceDestCheck(Boolean sourceDestCheck) Sets the value ofCfnNetworkInterfaceMixinProps.getSourceDestCheck()sourceDestCheck(IResolvable sourceDestCheck) Sets the value ofCfnNetworkInterfaceMixinProps.getSourceDestCheck()Sets the value ofCfnNetworkInterfaceMixinProps.getSubnetId()subnetId(ISubnetRef subnetId) Sets the value ofCfnNetworkInterfaceMixinProps.getSubnetId()Sets the value ofCfnNetworkInterfaceMixinProps.getTags()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
connectionTrackingSpecification
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder connectionTrackingSpecification(IResolvable connectionTrackingSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getConnectionTrackingSpecification()- Parameters:
connectionTrackingSpecification- A connection tracking specification for the network interface.- Returns:
this
-
connectionTrackingSpecification
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder connectionTrackingSpecification(CfnNetworkInterfacePropsMixin.ConnectionTrackingSpecificationProperty connectionTrackingSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getConnectionTrackingSpecification()- Parameters:
connectionTrackingSpecification- A connection tracking specification for the network interface.- Returns:
this
-
description
Sets the value ofCfnNetworkInterfaceMixinProps.getDescription()- Parameters:
description- A description for the network interface.- Returns:
this
-
enablePrimaryIpv6
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder enablePrimaryIpv6(Boolean enablePrimaryIpv6) Sets the value ofCfnNetworkInterfaceMixinProps.getEnablePrimaryIpv6()- Parameters:
enablePrimaryIpv6- If you’re modifying a network interface in a dual-stack or IPv6-only subnet, you have the option to assign a primary IPv6 IP address. A primary IPv6 address is an IPv6 GUA address associated with an ENI that you have enabled to use a primary IPv6 address. Use this option if the instance that this ENI will be attached to relies on its IPv6 address not changing. AWS will automatically assign an IPv6 address associated with the ENI attached to your instance to be the primary IPv6 address. Once you enable an IPv6 GUA address to be a primary IPv6, you cannot disable it. When you enable an IPv6 GUA address to be a primary IPv6, the first IPv6 GUA will be made the primary IPv6 address until the instance is terminated or the network interface is detached. If you have multiple IPv6 addresses associated with an ENI attached to your instance and you enable a primary IPv6 address, the first IPv6 GUA address associated with the ENI becomes the primary IPv6 address.- Returns:
this
-
enablePrimaryIpv6
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder enablePrimaryIpv6(IResolvable enablePrimaryIpv6) Sets the value ofCfnNetworkInterfaceMixinProps.getEnablePrimaryIpv6()- Parameters:
enablePrimaryIpv6- If you’re modifying a network interface in a dual-stack or IPv6-only subnet, you have the option to assign a primary IPv6 IP address. A primary IPv6 address is an IPv6 GUA address associated with an ENI that you have enabled to use a primary IPv6 address. Use this option if the instance that this ENI will be attached to relies on its IPv6 address not changing. AWS will automatically assign an IPv6 address associated with the ENI attached to your instance to be the primary IPv6 address. Once you enable an IPv6 GUA address to be a primary IPv6, you cannot disable it. When you enable an IPv6 GUA address to be a primary IPv6, the first IPv6 GUA will be made the primary IPv6 address until the instance is terminated or the network interface is detached. If you have multiple IPv6 addresses associated with an ENI attached to your instance and you enable a primary IPv6 address, the first IPv6 GUA address associated with the ENI becomes the primary IPv6 address.- Returns:
this
-
groupSet
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder groupSet(List<? extends Object> groupSet) Sets the value ofCfnNetworkInterfaceMixinProps.getGroupSet()- Parameters:
groupSet- The IDs of the security groups associated with this network interface.- Returns:
this
-
interfaceType
Sets the value ofCfnNetworkInterfaceMixinProps.getInterfaceType()- Parameters:
interfaceType- The type of network interface. The default isinterface. The supported values areefaandtrunk.- Returns:
this
-
ipv4PrefixCount
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv4PrefixCount(Number ipv4PrefixCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4PrefixCount()- Parameters:
ipv4PrefixCount- The number of IPv4 prefixes to be automatically assigned to the network interface. When creating a network interface, you can't specify a count of IPv4 prefixes if you've specified one of the following: specific IPv4 prefixes, specific private IPv4 addresses, or a count of private IPv4 addresses.- Returns:
this
-
ipv4Prefixes
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv4Prefixes(IResolvable ipv4Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4Prefixes()- Parameters:
ipv4Prefixes- The IPv4 delegated prefixes that are assigned to the network interface. When creating a network interface, you can't specify IPv4 prefixes if you've specified one of the following: a count of IPv4 prefixes, specific private IPv4 addresses, or a count of private IPv4 addresses.- Returns:
this
-
ipv4Prefixes
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv4Prefixes(List<? extends Object> ipv4Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv4Prefixes()- Parameters:
ipv4Prefixes- The IPv4 delegated prefixes that are assigned to the network interface. When creating a network interface, you can't specify IPv4 prefixes if you've specified one of the following: a count of IPv4 prefixes, specific private IPv4 addresses, or a count of private IPv4 addresses.- Returns:
this
-
ipv6AddressCount
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6AddressCount(Number ipv6AddressCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6AddressCount()- Parameters:
ipv6AddressCount- The number of IPv6 addresses to assign to the network interface. Amazon EC2 automatically selects the IPv6 addresses from the subnet range. To specify specific IPv6 addresses, use theIpv6Addressesproperty and don't specify this property.When creating a network interface, you can't specify a count of IPv6 addresses if you've specified one of the following: specific IPv6 addresses, specific IPv6 prefixes, or a count of IPv6 prefixes.
- Returns:
this
-
ipv6Addresses
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6Addresses(IResolvable ipv6Addresses) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Addresses()- Parameters:
ipv6Addresses- The IPv6 addresses from the IPv6 CIDR block range of your subnet to assign to the network interface. If you're specifying a number of IPv6 addresses, use theIpv6AddressCountproperty and don't specify this property.When creating a network interface, you can't specify IPv6 addresses if you've specified one of the following: a count of IPv6 addresses, specific IPv6 prefixes, or a count of IPv6 prefixes.
- Returns:
this
-
ipv6Addresses
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6Addresses(List<? extends Object> ipv6Addresses) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Addresses()- Parameters:
ipv6Addresses- The IPv6 addresses from the IPv6 CIDR block range of your subnet to assign to the network interface. If you're specifying a number of IPv6 addresses, use theIpv6AddressCountproperty and don't specify this property.When creating a network interface, you can't specify IPv6 addresses if you've specified one of the following: a count of IPv6 addresses, specific IPv6 prefixes, or a count of IPv6 prefixes.
- Returns:
this
-
ipv6PrefixCount
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6PrefixCount(Number ipv6PrefixCount) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6PrefixCount()- Parameters:
ipv6PrefixCount- The number of IPv6 prefixes to be automatically assigned to the network interface. When creating a network interface, you can't specify a count of IPv6 prefixes if you've specified one of the following: specific IPv6 prefixes, specific IPv6 addresses, or a count of IPv6 addresses.- Returns:
this
-
ipv6Prefixes
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6Prefixes(IResolvable ipv6Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Prefixes()- Parameters:
ipv6Prefixes- The IPv6 delegated prefixes that are assigned to the network interface. When creating a network interface, you can't specify IPv6 prefixes if you've specified one of the following: a count of IPv6 prefixes, specific IPv6 addresses, or a count of IPv6 addresses.- Returns:
this
-
ipv6Prefixes
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder ipv6Prefixes(List<? extends Object> ipv6Prefixes) Sets the value ofCfnNetworkInterfaceMixinProps.getIpv6Prefixes()- Parameters:
ipv6Prefixes- The IPv6 delegated prefixes that are assigned to the network interface. When creating a network interface, you can't specify IPv6 prefixes if you've specified one of the following: a count of IPv6 prefixes, specific IPv6 addresses, or a count of IPv6 addresses.- Returns:
this
-
privateIpAddress
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder privateIpAddress(String privateIpAddress) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddress()- Parameters:
privateIpAddress- The private IPv4 address to assign to the network interface as the primary private IP address. If you want to specify multiple private IP addresses, use thePrivateIpAddressesproperty.- Returns:
this
-
privateIpAddresses
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder privateIpAddresses(IResolvable privateIpAddresses) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddresses()- Parameters:
privateIpAddresses- The private IPv4 addresses to assign to the network interface. You can specify a primary private IP address by setting the value of thePrimaryproperty totruein thePrivateIpAddressSpecificationproperty. If you want EC2 to automatically assign private IP addresses, use theSecondaryPrivateIpAddressCountproperty and do not specify this property.When creating a network interface, you can't specify private IPv4 addresses if you've specified one of the following: a count of private IPv4 addresses, specific IPv4 prefixes, or a count of IPv4 prefixes.
- Returns:
this
-
privateIpAddresses
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder privateIpAddresses(List<? extends Object> privateIpAddresses) Sets the value ofCfnNetworkInterfaceMixinProps.getPrivateIpAddresses()- Parameters:
privateIpAddresses- The private IPv4 addresses to assign to the network interface. You can specify a primary private IP address by setting the value of thePrimaryproperty totruein thePrivateIpAddressSpecificationproperty. If you want EC2 to automatically assign private IP addresses, use theSecondaryPrivateIpAddressCountproperty and do not specify this property.When creating a network interface, you can't specify private IPv4 addresses if you've specified one of the following: a count of private IPv4 addresses, specific IPv4 prefixes, or a count of IPv4 prefixes.
- Returns:
this
-
publicIpDnsHostnameTypeSpecification
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder publicIpDnsHostnameTypeSpecification(String publicIpDnsHostnameTypeSpecification) Sets the value ofCfnNetworkInterfaceMixinProps.getPublicIpDnsHostnameTypeSpecification()- Parameters:
publicIpDnsHostnameTypeSpecification- Public IP DNS hostname type.- Returns:
this
-
secondaryPrivateIpAddressCount
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder secondaryPrivateIpAddressCount(Number secondaryPrivateIpAddressCount) Sets the value ofCfnNetworkInterfaceMixinProps.getSecondaryPrivateIpAddressCount()- Parameters:
secondaryPrivateIpAddressCount- The number of secondary private IPv4 addresses to assign to a network interface. When you specify a number of secondary IPv4 addresses, Amazon EC2 selects these IP addresses within the subnet's IPv4 CIDR range. You can't specify this option and specify more than one private IP address usingprivateIpAddresses.When creating a Network Interface, you can't specify a count of private IPv4 addresses if you've specified one of the following: specific private IPv4 addresses, specific IPv4 prefixes, or a count of IPv4 prefixes.
- Returns:
this
-
sourceDestCheck
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder sourceDestCheck(Boolean sourceDestCheck) Sets the value ofCfnNetworkInterfaceMixinProps.getSourceDestCheck()- Parameters:
sourceDestCheck- Enable or disable source/destination checks, which ensure that the instance is either the source or the destination of any traffic that it receives. If the value istrue, source/destination checks are enabled; otherwise, they are disabled. The default value istrue. You must disable source/destination checks if the instance runs services such as network address translation, routing, or firewalls.- Returns:
this
-
sourceDestCheck
@Stability(Stable) public CfnNetworkInterfaceMixinProps.Builder sourceDestCheck(IResolvable sourceDestCheck) Sets the value ofCfnNetworkInterfaceMixinProps.getSourceDestCheck()- Parameters:
sourceDestCheck- Enable or disable source/destination checks, which ensure that the instance is either the source or the destination of any traffic that it receives. If the value istrue, source/destination checks are enabled; otherwise, they are disabled. The default value istrue. You must disable source/destination checks if the instance runs services such as network address translation, routing, or firewalls.- Returns:
this
-
subnetId
Sets the value ofCfnNetworkInterfaceMixinProps.getSubnetId()- Parameters:
subnetId- The ID of the subnet to associate with the network interface.- Returns:
this
-
subnetId
Sets the value ofCfnNetworkInterfaceMixinProps.getSubnetId()- Parameters:
subnetId- The ID of the subnet to associate with the network interface.- Returns:
this
-
tags
Sets the value ofCfnNetworkInterfaceMixinProps.getTags()- Parameters:
tags- The tags to apply to the network interface.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnNetworkInterfaceMixinProps>- Returns:
- a new instance of
CfnNetworkInterfaceMixinProps - Throws:
NullPointerException- if any required attribute was not provided
-