Interface CreateDiskRequest.Builder

    • Method Detail

      • diskName

        CreateDiskRequest.Builder diskName​(String diskName)

        The unique Lightsail disk name (my-disk).

        Parameters:
        diskName - The unique Lightsail disk name (my-disk).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • availabilityZone

        CreateDiskRequest.Builder availabilityZone​(String availabilityZone)

        The Availability Zone where you want to create the disk (us-east-2a). Use the same Availability Zone as the Lightsail instance to which you want to attach the disk.

        Use the get regions operation to list the Availability Zones where Lightsail is currently available.

        Parameters:
        availabilityZone - The Availability Zone where you want to create the disk (us-east-2a). Use the same Availability Zone as the Lightsail instance to which you want to attach the disk.

        Use the get regions operation to list the Availability Zones where Lightsail is currently available.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • sizeInGb

        CreateDiskRequest.Builder sizeInGb​(Integer sizeInGb)

        The size of the disk in GB (32).

        Parameters:
        sizeInGb - The size of the disk in GB (32).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        CreateDiskRequest.Builder tags​(Collection<Tag> tags)

        The tag keys and optional values to add to the resource during create.

        Use the TagResource action to tag a resource after it's created.

        Parameters:
        tags - The tag keys and optional values to add to the resource during create.

        Use the TagResource action to tag a resource after it's created.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        CreateDiskRequest.Builder tags​(Tag... tags)

        The tag keys and optional values to add to the resource during create.

        Use the TagResource action to tag a resource after it's created.

        Parameters:
        tags - The tag keys and optional values to add to the resource during create.

        Use the TagResource action to tag a resource after it's created.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        CreateDiskRequest.Builder tags​(Consumer<Tag.Builder>... tags)

        The tag keys and optional values to add to the resource during create.

        Use the TagResource action to tag a resource after it's created.

        This is a convenience method that creates an instance of the Tag.Builder avoiding the need to create one manually via Tag.builder().

        When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to #tags(List).

        Parameters:
        tags - a consumer that will call methods on Tag.Builder
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        #tags(java.util.Collection)
      • addOns

        CreateDiskRequest.Builder addOns​(Collection<AddOnRequest> addOns)

        An array of objects that represent the add-ons to enable for the new disk.

        Parameters:
        addOns - An array of objects that represent the add-ons to enable for the new disk.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • addOns

        CreateDiskRequest.Builder addOns​(AddOnRequest... addOns)

        An array of objects that represent the add-ons to enable for the new disk.

        Parameters:
        addOns - An array of objects that represent the add-ons to enable for the new disk.
        Returns:
        Returns a reference to this object so that method calls can be chained together.