Class PoolOptions.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.alpha.PoolOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<PoolOptions>
- Enclosing interface:
PoolOptions
@Stability(Experimental)
public static final class PoolOptions.Builder
extends Object
implements software.amazon.jsii.Builder<PoolOptions>
A builder for
PoolOptions
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddressFamily
(AddressFamily addressFamily) Sets the value ofPoolOptions.getAddressFamily()
awsService
(AwsServiceName awsService) Sets the value ofPoolOptions.getAwsService()
build()
Builds the configured instance.ipv4ProvisionedCidrs
(List<String> ipv4ProvisionedCidrs) Sets the value ofPoolOptions.getIpv4ProvisionedCidrs()
Sets the value ofPoolOptions.getLocale()
publicIpSource
(IpamPoolPublicIpSource publicIpSource) Sets the value ofPoolOptions.getPublicIpSource()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
addressFamily
Sets the value ofPoolOptions.getAddressFamily()
- Parameters:
addressFamily
- addressFamily - The address family of the pool (ipv4 or ipv6). This parameter is required.- Returns:
this
-
awsService
Sets the value ofPoolOptions.getAwsService()
- Parameters:
awsService
- Limits which service in AWS that the pool can be used in. "ec2", for example, allows users to use space for Elastic IP addresses and VPCs.- Returns:
this
-
ipv4ProvisionedCidrs
@Stability(Experimental) public PoolOptions.Builder ipv4ProvisionedCidrs(List<String> ipv4ProvisionedCidrs) Sets the value ofPoolOptions.getIpv4ProvisionedCidrs()
- Parameters:
ipv4ProvisionedCidrs
- Information about the CIDRs provisioned to the pool.- Returns:
this
-
locale
Sets the value ofPoolOptions.getLocale()
- Parameters:
locale
- The locale (AWS Region) of the pool. Should be one of the IPAM operating region. Only resources in the same Region as the locale of the pool can get IP address allocations from the pool. You can only allocate a CIDR for a VPC, for example, from an IPAM pool that shares a locale with the VPC’s Region. Note that once you choose a Locale for a pool, you cannot modify it. If you choose an AWS Region for locale that has not been configured as an operating Region for the IPAM, you'll get an error.- Returns:
this
-
publicIpSource
@Stability(Experimental) public PoolOptions.Builder publicIpSource(IpamPoolPublicIpSource publicIpSource) Sets the value ofPoolOptions.getPublicIpSource()
- Parameters:
publicIpSource
- The IP address source for pools in the public scope. Only used for IPv6 address Only allowed values to this are 'byoip' or 'amazon'- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<PoolOptions>
- Returns:
- a new instance of
PoolOptions
- Throws:
NullPointerException
- if any required attribute was not provided
-