Class CfnDisk.Builder

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

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

    • create

      @Stability(Stable) public static CfnDisk.Builder create(Construct scope, String id)
      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
      Returns:
      a new instance of CfnDisk.Builder.
    • diskName

      @Stability(Stable) public CfnDisk.Builder diskName(String diskName)
      The name of the disk.

      Parameters:
      diskName - The name of the disk. This parameter is required.
      Returns:
      this
    • sizeInGb

      @Stability(Stable) public CfnDisk.Builder sizeInGb(Number sizeInGb)
      The size of the disk in GB.

      Parameters:
      sizeInGb - The size of the disk in GB. This parameter is required.
      Returns:
      this
    • addOns

      @Stability(Stable) public CfnDisk.Builder addOns(IResolvable addOns)
      An array of add-ons for the disk.

      If the disk has an add-on enabled when performing a delete disk request, the add-on is automatically disabled before the disk is deleted.

      Parameters:
      addOns - An array of add-ons for the disk. This parameter is required.
      Returns:
      this
    • addOns

      @Stability(Stable) public CfnDisk.Builder addOns(List<? extends Object> addOns)
      An array of add-ons for the disk.

      If the disk has an add-on enabled when performing a delete disk request, the add-on is automatically disabled before the disk is deleted.

      Parameters:
      addOns - An array of add-ons for the disk. This parameter is required.
      Returns:
      this
    • availabilityZone

      @Stability(Stable) public CfnDisk.Builder availabilityZone(String availabilityZone)
      The AWS Region and Availability Zone location for the disk (for example, us-east-1a ).

      Parameters:
      availabilityZone - The AWS Region and Availability Zone location for the disk (for example, us-east-1a ). This parameter is required.
      Returns:
      this
    • location

      @Stability(Stable) public CfnDisk.Builder location(IResolvable location)
      AWS::Lightsail::Disk.Location.

      Parameters:
      location - AWS::Lightsail::Disk.Location. This parameter is required.
      Returns:
      this
    • location

      @Stability(Stable) public CfnDisk.Builder location(CfnDisk.LocationProperty location)
      AWS::Lightsail::Disk.Location.

      Parameters:
      location - AWS::Lightsail::Disk.Location. This parameter is required.
      Returns:
      this
    • tags

      @Stability(Stable) public CfnDisk.Builder tags(List<? extends CfnTag> tags)
      An array of key-value pairs to apply to this resource.

      For more information, see Tag in the AWS CloudFormation User Guide .

      The Value of Tags is optional for Lightsail resources.

      Parameters:
      tags - An array of key-value pairs to apply to this resource. This parameter is required.
      Returns:
      this
    • build

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