Class CfnClientVpnRouteProps.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.CfnClientVpnRouteProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnClientVpnRouteProps>
- Enclosing interface:
CfnClientVpnRouteProps
@Stability(Stable)
public static final class CfnClientVpnRouteProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnClientVpnRouteProps>
A builder for
CfnClientVpnRouteProps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.clientVpnEndpointId
(String clientVpnEndpointId) Sets the value ofCfnClientVpnRouteProps.getClientVpnEndpointId()
description
(String description) Sets the value ofCfnClientVpnRouteProps.getDescription()
destinationCidrBlock
(String destinationCidrBlock) Sets the value ofCfnClientVpnRouteProps.getDestinationCidrBlock()
targetVpcSubnetId
(String targetVpcSubnetId) Sets the value ofCfnClientVpnRouteProps.getTargetVpcSubnetId()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
clientVpnEndpointId
@Stability(Stable) public CfnClientVpnRouteProps.Builder clientVpnEndpointId(String clientVpnEndpointId) Sets the value ofCfnClientVpnRouteProps.getClientVpnEndpointId()
- Parameters:
clientVpnEndpointId
- The ID of the Client VPN endpoint to which to add the route. This parameter is required.- Returns:
this
-
destinationCidrBlock
@Stability(Stable) public CfnClientVpnRouteProps.Builder destinationCidrBlock(String destinationCidrBlock) Sets the value ofCfnClientVpnRouteProps.getDestinationCidrBlock()
- Parameters:
destinationCidrBlock
- The IPv4 address range, in CIDR notation, of the route destination. For example:. This parameter is required.- To add a route for Internet access, enter
0.0.0.0/0
- To add a route for a peered VPC, enter the peered VPC's IPv4 CIDR range
- To add a route for an on-premises network, enter the AWS Site-to-Site VPN connection's IPv4 CIDR range
- To add a route for the local network, enter the client CIDR range
- To add a route for Internet access, enter
- Returns:
this
-
targetVpcSubnetId
@Stability(Stable) public CfnClientVpnRouteProps.Builder targetVpcSubnetId(String targetVpcSubnetId) Sets the value ofCfnClientVpnRouteProps.getTargetVpcSubnetId()
- Parameters:
targetVpcSubnetId
- The ID of the subnet through which you want to route traffic. This parameter is required. The specified subnet must be an existing target network of the Client VPN endpoint.Alternatively, if you're adding a route for the local network, specify
local
.- Returns:
this
-
description
Sets the value ofCfnClientVpnRouteProps.getDescription()
- Parameters:
description
- A brief description of the route.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnClientVpnRouteProps>
- Returns:
- a new instance of
CfnClientVpnRouteProps
- Throws:
NullPointerException
- if any required attribute was not provided
-