Class NetworkAcl.Builder

java.lang.Object
software.amazon.awscdk.services.ec2.NetworkAcl.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<NetworkAcl>
Enclosing class:
NetworkAcl

@Stability(Stable) public static final class NetworkAcl.Builder extends Object implements software.amazon.jsii.Builder<NetworkAcl>
A fluent builder for NetworkAcl.
  • Method Details

    • create

      @Stability(Stable) public static NetworkAcl.Builder create(software.constructs.Construct scope, String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      Returns:
      a new instance of NetworkAcl.Builder.
    • vpc

      @Stability(Stable) public NetworkAcl.Builder vpc(IVpc vpc)
      The VPC in which to create the NetworkACL.

      Parameters:
      vpc - The VPC in which to create the NetworkACL. This parameter is required.
      Returns:
      this
    • networkAclName

      @Stability(Stable) public NetworkAcl.Builder networkAclName(String networkAclName)
      The name of the NetworkAcl.

      It is not recommended to use an explicit name.

      Default: If you don't specify a networkAclName, AWS CloudFormation generates a unique physical ID and uses that ID for the group name.

      Parameters:
      networkAclName - The name of the NetworkAcl. This parameter is required.
      Returns:
      this
    • subnetSelection

      @Stability(Stable) public NetworkAcl.Builder subnetSelection(SubnetSelection subnetSelection)
      Subnets in the given VPC to associate the ACL with.

      More subnets can always be added later by calling associateWithSubnets().

      Default: - No subnets associated

      Parameters:
      subnetSelection - Subnets in the given VPC to associate the ACL with. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public NetworkAcl build()
      Specified by:
      build in interface software.amazon.jsii.Builder<NetworkAcl>
      Returns:
      a newly built instance of NetworkAcl.