Class CfnHostProps.Builder

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

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

    • Builder

      public Builder()
  • Method Details

    • availabilityZone

      @Stability(Stable) public CfnHostProps.Builder availabilityZone(String availabilityZone)
      Parameters:
      availabilityZone - The Availability Zone in which to allocate the Dedicated Host. This parameter is required.
      Returns:
      this
    • assetId

      @Stability(Stable) public CfnHostProps.Builder assetId(String assetId)
      Sets the value of CfnHostProps.getAssetId()
      Parameters:
      assetId - The ID of the Outpost hardware asset on which the Dedicated Host is allocated.
      Returns:
      this
    • autoPlacement

      @Stability(Stable) public CfnHostProps.Builder autoPlacement(String autoPlacement)
      Parameters:
      autoPlacement - Indicates whether the host accepts any untargeted instance launches that match its instance type configuration, or if it only accepts Host tenancy instance launches that specify its unique host ID. For more information, see Understanding auto-placement and affinity in the Amazon EC2 User Guide .

      Default: off

      Returns:
      this
    • hostMaintenance

      @Stability(Stable) public CfnHostProps.Builder hostMaintenance(String hostMaintenance)
      Parameters:
      hostMaintenance - Indicates whether host maintenance is enabled or disabled for the Dedicated Host.
      Returns:
      this
    • hostRecovery

      @Stability(Stable) public CfnHostProps.Builder hostRecovery(String hostRecovery)
      Parameters:
      hostRecovery - Indicates whether to enable or disable host recovery for the Dedicated Host. Host recovery is disabled by default. For more information, see Host recovery in the Amazon EC2 User Guide .

      Default: off

      Returns:
      this
    • instanceFamily

      @Stability(Stable) public CfnHostProps.Builder instanceFamily(String instanceFamily)
      Parameters:
      instanceFamily - The instance family supported by the Dedicated Host. For example, m5 .
      Returns:
      this
    • instanceType

      @Stability(Stable) public CfnHostProps.Builder instanceType(String instanceType)
      Parameters:
      instanceType - Specifies the instance type to be supported by the Dedicated Hosts. If you specify an instance type, the Dedicated Hosts support instances of the specified instance type only.
      Returns:
      this
    • outpostArn

      @Stability(Stable) public CfnHostProps.Builder outpostArn(String outpostArn)
      Parameters:
      outpostArn - The Amazon Resource Name (ARN) of the AWS Outpost on which the Dedicated Host is allocated.
      Returns:
      this
    • build

      @Stability(Stable) public CfnHostProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnHostProps>
      Returns:
      a new instance of CfnHostProps
      Throws:
      NullPointerException - if any required attribute was not provided