Interface Subnet.Builder
-
- All Superinterfaces:
Buildable
,CopyableBuilder<Subnet.Builder,Subnet>
,SdkBuilder<Subnet.Builder,Subnet>
,SdkPojo
- Enclosing class:
- Subnet
public static interface Subnet.Builder extends SdkPojo, CopyableBuilder<Subnet.Builder,Subnet>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description Subnet.Builder
assignIpv6AddressOnCreation(Boolean assignIpv6AddressOnCreation)
Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives an IPv6 address.Subnet.Builder
availabilityZone(String availabilityZone)
The Availability Zone of the subnet.Subnet.Builder
availabilityZoneId(String availabilityZoneId)
The AZ ID of the subnet.Subnet.Builder
availableIpAddressCount(Integer availableIpAddressCount)
The number of unused private IPv4 addresses in the subnet.default Subnet.Builder
blockPublicAccessStates(Consumer<BlockPublicAccessStates.Builder> blockPublicAccessStates)
The state of VPC Block Public Access (BPA).Subnet.Builder
blockPublicAccessStates(BlockPublicAccessStates blockPublicAccessStates)
The state of VPC Block Public Access (BPA).Subnet.Builder
cidrBlock(String cidrBlock)
The IPv4 CIDR block assigned to the subnet.Subnet.Builder
customerOwnedIpv4Pool(String customerOwnedIpv4Pool)
The customer-owned IPv4 address pool associated with the subnet.Subnet.Builder
defaultForAz(Boolean defaultForAz)
Indicates whether this is the default subnet for the Availability Zone.Subnet.Builder
enableDns64(Boolean enableDns64)
Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations.Subnet.Builder
enableLniAtDeviceIndex(Integer enableLniAtDeviceIndex)
Indicates the device position for local network interfaces in this subnet.Subnet.Builder
ipv6CidrBlockAssociationSet(Collection<SubnetIpv6CidrBlockAssociation> ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.Subnet.Builder
ipv6CidrBlockAssociationSet(Consumer<SubnetIpv6CidrBlockAssociation.Builder>... ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.Subnet.Builder
ipv6CidrBlockAssociationSet(SubnetIpv6CidrBlockAssociation... ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.Subnet.Builder
ipv6Native(Boolean ipv6Native)
Indicates whether this is an IPv6 only subnet.Subnet.Builder
mapCustomerOwnedIpOnLaunch(Boolean mapCustomerOwnedIpOnLaunch)
Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives a customer-owned IPv4 address.Subnet.Builder
mapPublicIpOnLaunch(Boolean mapPublicIpOnLaunch)
Indicates whether instances launched in this subnet receive a public IPv4 address.Subnet.Builder
outpostArn(String outpostArn)
The Amazon Resource Name (ARN) of the Outpost.Subnet.Builder
ownerId(String ownerId)
The ID of the Amazon Web Services account that owns the subnet.default Subnet.Builder
privateDnsNameOptionsOnLaunch(Consumer<PrivateDnsNameOptionsOnLaunch.Builder> privateDnsNameOptionsOnLaunch)
The type of hostnames to assign to instances in the subnet at launch.Subnet.Builder
privateDnsNameOptionsOnLaunch(PrivateDnsNameOptionsOnLaunch privateDnsNameOptionsOnLaunch)
The type of hostnames to assign to instances in the subnet at launch.Subnet.Builder
state(String state)
The current state of the subnet.Subnet.Builder
state(SubnetState state)
The current state of the subnet.Subnet.Builder
subnetArn(String subnetArn)
The Amazon Resource Name (ARN) of the subnet.Subnet.Builder
subnetId(String subnetId)
The ID of the subnet.Subnet.Builder
tags(Collection<Tag> tags)
Any tags assigned to the subnet.Subnet.Builder
tags(Consumer<Tag.Builder>... tags)
Any tags assigned to the subnet.Subnet.Builder
tags(Tag... tags)
Any tags assigned to the subnet.Subnet.Builder
vpcId(String vpcId)
The ID of the VPC the subnet is in.-
Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
-
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
-
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
-
-
-
Method Detail
-
availabilityZoneId
Subnet.Builder availabilityZoneId(String availabilityZoneId)
The AZ ID of the subnet.
- Parameters:
availabilityZoneId
- The AZ ID of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
enableLniAtDeviceIndex
Subnet.Builder enableLniAtDeviceIndex(Integer enableLniAtDeviceIndex)
Indicates the device position for local network interfaces in this subnet. For example,
1
indicates local network interfaces in this subnet are the secondary network interface (eth1).- Parameters:
enableLniAtDeviceIndex
- Indicates the device position for local network interfaces in this subnet. For example,1
indicates local network interfaces in this subnet are the secondary network interface (eth1).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
mapCustomerOwnedIpOnLaunch
Subnet.Builder mapCustomerOwnedIpOnLaunch(Boolean mapCustomerOwnedIpOnLaunch)
Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives a customer-owned IPv4 address.
- Parameters:
mapCustomerOwnedIpOnLaunch
- Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives a customer-owned IPv4 address.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
customerOwnedIpv4Pool
Subnet.Builder customerOwnedIpv4Pool(String customerOwnedIpv4Pool)
The customer-owned IPv4 address pool associated with the subnet.
- Parameters:
customerOwnedIpv4Pool
- The customer-owned IPv4 address pool associated with the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
ownerId
Subnet.Builder ownerId(String ownerId)
The ID of the Amazon Web Services account that owns the subnet.
- Parameters:
ownerId
- The ID of the Amazon Web Services account that owns the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
assignIpv6AddressOnCreation
Subnet.Builder assignIpv6AddressOnCreation(Boolean assignIpv6AddressOnCreation)
Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives an IPv6 address.
- Parameters:
assignIpv6AddressOnCreation
- Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives an IPv6 address.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
ipv6CidrBlockAssociationSet
Subnet.Builder ipv6CidrBlockAssociationSet(Collection<SubnetIpv6CidrBlockAssociation> ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.
- Parameters:
ipv6CidrBlockAssociationSet
- Information about the IPv6 CIDR blocks associated with the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
ipv6CidrBlockAssociationSet
Subnet.Builder ipv6CidrBlockAssociationSet(SubnetIpv6CidrBlockAssociation... ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.
- Parameters:
ipv6CidrBlockAssociationSet
- Information about the IPv6 CIDR blocks associated with the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
ipv6CidrBlockAssociationSet
Subnet.Builder ipv6CidrBlockAssociationSet(Consumer<SubnetIpv6CidrBlockAssociation.Builder>... ipv6CidrBlockAssociationSet)
Information about the IPv6 CIDR blocks associated with the subnet.
This is a convenience method that creates an instance of theSubnetIpv6CidrBlockAssociation.Builder
avoiding the need to create one manually viaSubnetIpv6CidrBlockAssociation.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed to#ipv6CidrBlockAssociationSet(List
.) - Parameters:
ipv6CidrBlockAssociationSet
- a consumer that will call methods onSubnetIpv6CidrBlockAssociation.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
#ipv6CidrBlockAssociationSet(java.util.Collection
)
-
tags
Subnet.Builder tags(Collection<Tag> tags)
Any tags assigned to the subnet.
- Parameters:
tags
- Any tags assigned to the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
tags
Subnet.Builder tags(Tag... tags)
Any tags assigned to the subnet.
- Parameters:
tags
- Any tags assigned to the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
tags
Subnet.Builder tags(Consumer<Tag.Builder>... tags)
Any tags assigned to the subnet.
This is a convenience method that creates an instance of theTag.Builder
avoiding the need to create one manually viaTag.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed to#tags(List
.) - Parameters:
tags
- a consumer that will call methods onTag.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
#tags(java.util.Collection
)
-
subnetArn
Subnet.Builder subnetArn(String subnetArn)
The Amazon Resource Name (ARN) of the subnet.
- Parameters:
subnetArn
- The Amazon Resource Name (ARN) of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
outpostArn
Subnet.Builder outpostArn(String outpostArn)
The Amazon Resource Name (ARN) of the Outpost.
- Parameters:
outpostArn
- The Amazon Resource Name (ARN) of the Outpost.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
enableDns64
Subnet.Builder enableDns64(Boolean enableDns64)
Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations.
- Parameters:
enableDns64
- Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
ipv6Native
Subnet.Builder ipv6Native(Boolean ipv6Native)
Indicates whether this is an IPv6 only subnet.
- Parameters:
ipv6Native
- Indicates whether this is an IPv6 only subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
privateDnsNameOptionsOnLaunch
Subnet.Builder privateDnsNameOptionsOnLaunch(PrivateDnsNameOptionsOnLaunch privateDnsNameOptionsOnLaunch)
The type of hostnames to assign to instances in the subnet at launch. An instance hostname is based on the IPv4 address or ID of the instance.
- Parameters:
privateDnsNameOptionsOnLaunch
- The type of hostnames to assign to instances in the subnet at launch. An instance hostname is based on the IPv4 address or ID of the instance.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
privateDnsNameOptionsOnLaunch
default Subnet.Builder privateDnsNameOptionsOnLaunch(Consumer<PrivateDnsNameOptionsOnLaunch.Builder> privateDnsNameOptionsOnLaunch)
The type of hostnames to assign to instances in the subnet at launch. An instance hostname is based on the IPv4 address or ID of the instance.
This is a convenience method that creates an instance of thePrivateDnsNameOptionsOnLaunch.Builder
avoiding the need to create one manually viaPrivateDnsNameOptionsOnLaunch.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toprivateDnsNameOptionsOnLaunch(PrivateDnsNameOptionsOnLaunch)
.- Parameters:
privateDnsNameOptionsOnLaunch
- a consumer that will call methods onPrivateDnsNameOptionsOnLaunch.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
privateDnsNameOptionsOnLaunch(PrivateDnsNameOptionsOnLaunch)
-
blockPublicAccessStates
Subnet.Builder blockPublicAccessStates(BlockPublicAccessStates blockPublicAccessStates)
The state of VPC Block Public Access (BPA).
- Parameters:
blockPublicAccessStates
- The state of VPC Block Public Access (BPA).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
blockPublicAccessStates
default Subnet.Builder blockPublicAccessStates(Consumer<BlockPublicAccessStates.Builder> blockPublicAccessStates)
The state of VPC Block Public Access (BPA).
This is a convenience method that creates an instance of theBlockPublicAccessStates.Builder
avoiding the need to create one manually viaBlockPublicAccessStates.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toblockPublicAccessStates(BlockPublicAccessStates)
.- Parameters:
blockPublicAccessStates
- a consumer that will call methods onBlockPublicAccessStates.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
blockPublicAccessStates(BlockPublicAccessStates)
-
subnetId
Subnet.Builder subnetId(String subnetId)
The ID of the subnet.
- Parameters:
subnetId
- The ID of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
state
Subnet.Builder state(String state)
The current state of the subnet.
- Parameters:
state
- The current state of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
SubnetState
,SubnetState
-
state
Subnet.Builder state(SubnetState state)
The current state of the subnet.
- Parameters:
state
- The current state of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
SubnetState
,SubnetState
-
vpcId
Subnet.Builder vpcId(String vpcId)
The ID of the VPC the subnet is in.
- Parameters:
vpcId
- The ID of the VPC the subnet is in.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
cidrBlock
Subnet.Builder cidrBlock(String cidrBlock)
The IPv4 CIDR block assigned to the subnet.
- Parameters:
cidrBlock
- The IPv4 CIDR block assigned to the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
availableIpAddressCount
Subnet.Builder availableIpAddressCount(Integer availableIpAddressCount)
The number of unused private IPv4 addresses in the subnet. The IPv4 addresses for any stopped instances are considered unavailable.
- Parameters:
availableIpAddressCount
- The number of unused private IPv4 addresses in the subnet. The IPv4 addresses for any stopped instances are considered unavailable.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
availabilityZone
Subnet.Builder availabilityZone(String availabilityZone)
The Availability Zone of the subnet.
- Parameters:
availabilityZone
- The Availability Zone of the subnet.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
defaultForAz
Subnet.Builder defaultForAz(Boolean defaultForAz)
Indicates whether this is the default subnet for the Availability Zone.
- Parameters:
defaultForAz
- Indicates whether this is the default subnet for the Availability Zone.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
mapPublicIpOnLaunch
Subnet.Builder mapPublicIpOnLaunch(Boolean mapPublicIpOnLaunch)
Indicates whether instances launched in this subnet receive a public IPv4 address.
Amazon Web Services charges for all public IPv4 addresses, including public IPv4 addresses associated with running instances and Elastic IP addresses. For more information, see the Public IPv4 Address tab on the Amazon VPC pricing page.
- Parameters:
mapPublicIpOnLaunch
- Indicates whether instances launched in this subnet receive a public IPv4 address.Amazon Web Services charges for all public IPv4 addresses, including public IPv4 addresses associated with running instances and Elastic IP addresses. For more information, see the Public IPv4 Address tab on the Amazon VPC pricing page.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-