Class CfnDHCPOptions

java.lang.Object
software.amazon.jsii.JsiiObject
All Implemented Interfaces:
IConstruct, IDependable, IInspectable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:38.465Z") @Stability(Stable) public class CfnDHCPOptions extends CfnResource implements IInspectable
A CloudFormation AWS::EC2::DHCPOptions.

Specifies a set of DHCP options for your VPC.

You must specify at least one of the following properties: DomainNameServers , NetbiosNameServers , NtpServers . If you specify NetbiosNameServers , you must specify NetbiosNodeType .

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.ec2.*;
 CfnDHCPOptions cfnDHCPOptions = CfnDHCPOptions.Builder.create(this, "MyCfnDHCPOptions")
         .domainName("domainName")
         .domainNameServers(List.of("domainNameServers"))
         .netbiosNameServers(List.of("netbiosNameServers"))
         .netbiosNodeType(123)
         .ntpServers(List.of("ntpServers"))
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .build();
 
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnDHCPOptions

      protected CfnDHCPOptions(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnDHCPOptions

      protected CfnDHCPOptions(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnDHCPOptions

      @Stability(Stable) public CfnDHCPOptions(@NotNull Construct scope, @NotNull String id, @Nullable CfnDHCPOptionsProps props)
      Create a new AWS::EC2::DHCPOptions.

      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
      props -
      • resource properties.
    • CfnDHCPOptions

      @Stability(Stable) public CfnDHCPOptions(@NotNull Construct scope, @NotNull String id)
      Create a new AWS::EC2::DHCPOptions.

      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
  • Method Details

    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector -
      • tree inspector to collect and process attributes.
      This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrDhcpOptionsId

      @Stability(Stable) @NotNull public String getAttrDhcpOptionsId()
      The ID of the DHCP options set.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getTags

      @Stability(Stable) @NotNull public TagManager getTags()
      Any tags assigned to the DHCP options set.
    • getDomainName

      @Stability(Stable) @Nullable public String getDomainName()
      This value is used to complete unqualified DNS hostnames.

      If you're using AmazonProvidedDNS in us-east-1 , specify ec2.internal . If you're using AmazonProvidedDNS in another Region, specify region . compute.internal (for example, ap-northeast-1.compute.internal ). Otherwise, specify a domain name (for example, MyCompany.com ).

    • setDomainName

      @Stability(Stable) public void setDomainName(@Nullable String value)
      This value is used to complete unqualified DNS hostnames.

      If you're using AmazonProvidedDNS in us-east-1 , specify ec2.internal . If you're using AmazonProvidedDNS in another Region, specify region . compute.internal (for example, ap-northeast-1.compute.internal ). Otherwise, specify a domain name (for example, MyCompany.com ).

    • getDomainNameServers

      @Stability(Stable) @Nullable public List<String> getDomainNameServers()
      The IPv4 addresses of up to four domain name servers, or AmazonProvidedDNS .

      The default is AmazonProvidedDNS . To have your instance receive a custom DNS hostname as specified in DomainName , you must set this property to a custom DNS server.

    • setDomainNameServers

      @Stability(Stable) public void setDomainNameServers(@Nullable List<String> value)
      The IPv4 addresses of up to four domain name servers, or AmazonProvidedDNS .

      The default is AmazonProvidedDNS . To have your instance receive a custom DNS hostname as specified in DomainName , you must set this property to a custom DNS server.

    • getNetbiosNameServers

      @Stability(Stable) @Nullable public List<String> getNetbiosNameServers()
      The IPv4 addresses of up to four NetBIOS name servers.
    • setNetbiosNameServers

      @Stability(Stable) public void setNetbiosNameServers(@Nullable List<String> value)
      The IPv4 addresses of up to four NetBIOS name servers.
    • getNetbiosNodeType

      @Stability(Stable) @Nullable public Number getNetbiosNodeType()
      The NetBIOS node type (1, 2, 4, or 8).

      We recommend that you specify 2 (broadcast and multicast are not currently supported).

    • setNetbiosNodeType

      @Stability(Stable) public void setNetbiosNodeType(@Nullable Number value)
      The NetBIOS node type (1, 2, 4, or 8).

      We recommend that you specify 2 (broadcast and multicast are not currently supported).

    • getNtpServers

      @Stability(Stable) @Nullable public List<String> getNtpServers()
      The IPv4 addresses of up to four Network Time Protocol (NTP) servers.
    • setNtpServers

      @Stability(Stable) public void setNtpServers(@Nullable List<String> value)
      The IPv4 addresses of up to four Network Time Protocol (NTP) servers.