Interface CapacityReservation.Builder

    • Method Detail

      • capacityReservationId

        CapacityReservation.Builder capacityReservationId​(String capacityReservationId)

        The ID of the Capacity Reservation.

        Parameters:
        capacityReservationId - The ID of the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ownerId

        CapacityReservation.Builder ownerId​(String ownerId)

        The ID of the Amazon Web Services account that owns the Capacity Reservation.

        Parameters:
        ownerId - The ID of the Amazon Web Services account that owns the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • capacityReservationArn

        CapacityReservation.Builder capacityReservationArn​(String capacityReservationArn)

        The Amazon Resource Name (ARN) of the Capacity Reservation.

        Parameters:
        capacityReservationArn - The Amazon Resource Name (ARN) of the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • availabilityZoneId

        CapacityReservation.Builder availabilityZoneId​(String availabilityZoneId)

        The Availability Zone ID of the Capacity Reservation.

        Parameters:
        availabilityZoneId - The Availability Zone ID of the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • instanceType

        CapacityReservation.Builder instanceType​(String instanceType)

        The type of instance for which the Capacity Reservation reserves capacity.

        Parameters:
        instanceType - The type of instance for which the Capacity Reservation reserves capacity.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • availabilityZone

        CapacityReservation.Builder availabilityZone​(String availabilityZone)

        The Availability Zone in which the capacity is reserved.

        Parameters:
        availabilityZone - The Availability Zone in which the capacity is reserved.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tenancy

        CapacityReservation.Builder tenancy​(String tenancy)

        Indicates the tenancy of the Capacity Reservation. A Capacity Reservation can have one of the following tenancy settings:

        • default - The Capacity Reservation is created on hardware that is shared with other Amazon Web Services accounts.

        • dedicated - The Capacity Reservation is created on single-tenant hardware that is dedicated to a single Amazon Web Services account.

        Parameters:
        tenancy - Indicates the tenancy of the Capacity Reservation. A Capacity Reservation can have one of the following tenancy settings:

        • default - The Capacity Reservation is created on hardware that is shared with other Amazon Web Services accounts.

        • dedicated - The Capacity Reservation is created on single-tenant hardware that is dedicated to a single Amazon Web Services account.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        CapacityReservationTenancy, CapacityReservationTenancy
      • tenancy

        CapacityReservation.Builder tenancy​(CapacityReservationTenancy tenancy)

        Indicates the tenancy of the Capacity Reservation. A Capacity Reservation can have one of the following tenancy settings:

        • default - The Capacity Reservation is created on hardware that is shared with other Amazon Web Services accounts.

        • dedicated - The Capacity Reservation is created on single-tenant hardware that is dedicated to a single Amazon Web Services account.

        Parameters:
        tenancy - Indicates the tenancy of the Capacity Reservation. A Capacity Reservation can have one of the following tenancy settings:

        • default - The Capacity Reservation is created on hardware that is shared with other Amazon Web Services accounts.

        • dedicated - The Capacity Reservation is created on single-tenant hardware that is dedicated to a single Amazon Web Services account.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        CapacityReservationTenancy, CapacityReservationTenancy
      • totalInstanceCount

        CapacityReservation.Builder totalInstanceCount​(Integer totalInstanceCount)

        The total number of instances for which the Capacity Reservation reserves capacity.

        Parameters:
        totalInstanceCount - The total number of instances for which the Capacity Reservation reserves capacity.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • availableInstanceCount

        CapacityReservation.Builder availableInstanceCount​(Integer availableInstanceCount)

        The remaining capacity. Indicates the number of instances that can be launched in the Capacity Reservation.

        Parameters:
        availableInstanceCount - The remaining capacity. Indicates the number of instances that can be launched in the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ebsOptimized

        CapacityReservation.Builder ebsOptimized​(Boolean ebsOptimized)

        Indicates whether the Capacity Reservation supports EBS-optimized instances. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS- optimized instance.

        Parameters:
        ebsOptimized - Indicates whether the Capacity Reservation supports EBS-optimized instances. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS- optimized instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ephemeralStorage

        CapacityReservation.Builder ephemeralStorage​(Boolean ephemeralStorage)

        Deprecated.

        Parameters:
        ephemeralStorage - Deprecated.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • state

        CapacityReservation.Builder state​(String state)

        The current state of the Capacity Reservation. A Capacity Reservation can be in one of the following states:

        • active - The Capacity Reservation is active and the capacity is available for your use.

        • expired - The Capacity Reservation expired automatically at the date and time specified in your request. The reserved capacity is no longer available for your use.

        • cancelled - The Capacity Reservation was cancelled. The reserved capacity is no longer available for your use.

        • pending - The Capacity Reservation request was successful but the capacity provisioning is still pending.

        • failed - The Capacity Reservation request has failed. A request might fail due to invalid request parameters, capacity constraints, or instance limit constraints. Failed requests are retained for 60 minutes.

        Parameters:
        state - The current state of the Capacity Reservation. A Capacity Reservation can be in one of the following states:

        • active - The Capacity Reservation is active and the capacity is available for your use.

        • expired - The Capacity Reservation expired automatically at the date and time specified in your request. The reserved capacity is no longer available for your use.

        • cancelled - The Capacity Reservation was cancelled. The reserved capacity is no longer available for your use.

        • pending - The Capacity Reservation request was successful but the capacity provisioning is still pending.

        • failed - The Capacity Reservation request has failed. A request might fail due to invalid request parameters, capacity constraints, or instance limit constraints. Failed requests are retained for 60 minutes.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        CapacityReservationState, CapacityReservationState
      • state

        CapacityReservation.Builder state​(CapacityReservationState state)

        The current state of the Capacity Reservation. A Capacity Reservation can be in one of the following states:

        • active - The Capacity Reservation is active and the capacity is available for your use.

        • expired - The Capacity Reservation expired automatically at the date and time specified in your request. The reserved capacity is no longer available for your use.

        • cancelled - The Capacity Reservation was cancelled. The reserved capacity is no longer available for your use.

        • pending - The Capacity Reservation request was successful but the capacity provisioning is still pending.

        • failed - The Capacity Reservation request has failed. A request might fail due to invalid request parameters, capacity constraints, or instance limit constraints. Failed requests are retained for 60 minutes.

        Parameters:
        state - The current state of the Capacity Reservation. A Capacity Reservation can be in one of the following states:

        • active - The Capacity Reservation is active and the capacity is available for your use.

        • expired - The Capacity Reservation expired automatically at the date and time specified in your request. The reserved capacity is no longer available for your use.

        • cancelled - The Capacity Reservation was cancelled. The reserved capacity is no longer available for your use.

        • pending - The Capacity Reservation request was successful but the capacity provisioning is still pending.

        • failed - The Capacity Reservation request has failed. A request might fail due to invalid request parameters, capacity constraints, or instance limit constraints. Failed requests are retained for 60 minutes.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        CapacityReservationState, CapacityReservationState
      • startDate

        CapacityReservation.Builder startDate​(Instant startDate)

        The date and time at which the Capacity Reservation was started.

        Parameters:
        startDate - The date and time at which the Capacity Reservation was started.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • endDate

        CapacityReservation.Builder endDate​(Instant endDate)

        The date and time at which the Capacity Reservation expires. When a Capacity Reservation expires, the reserved capacity is released and you can no longer launch instances into it. The Capacity Reservation's state changes to expired when it reaches its end date and time.

        Parameters:
        endDate - The date and time at which the Capacity Reservation expires. When a Capacity Reservation expires, the reserved capacity is released and you can no longer launch instances into it. The Capacity Reservation's state changes to expired when it reaches its end date and time.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • endDateType

        CapacityReservation.Builder endDateType​(String endDateType)

        Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:

        • unlimited - The Capacity Reservation remains active until you explicitly cancel it.

        • limited - The Capacity Reservation expires automatically at a specified date and time.

        Parameters:
        endDateType - Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:

        • unlimited - The Capacity Reservation remains active until you explicitly cancel it.

        • limited - The Capacity Reservation expires automatically at a specified date and time.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        EndDateType, EndDateType
      • endDateType

        CapacityReservation.Builder endDateType​(EndDateType endDateType)

        Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:

        • unlimited - The Capacity Reservation remains active until you explicitly cancel it.

        • limited - The Capacity Reservation expires automatically at a specified date and time.

        Parameters:
        endDateType - Indicates the way in which the Capacity Reservation ends. A Capacity Reservation can have one of the following end types:

        • unlimited - The Capacity Reservation remains active until you explicitly cancel it.

        • limited - The Capacity Reservation expires automatically at a specified date and time.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        EndDateType, EndDateType
      • instanceMatchCriteria

        CapacityReservation.Builder instanceMatchCriteria​(String instanceMatchCriteria)

        Indicates the type of instance launches that the Capacity Reservation accepts. The options include:

        • open - The Capacity Reservation accepts all instances that have matching attributes (instance type, platform, and Availability Zone). Instances that have matching attributes launch into the Capacity Reservation automatically without specifying any additional parameters.

        • targeted - The Capacity Reservation only accepts instances that have matching attributes (instance type, platform, and Availability Zone), and explicitly target the Capacity Reservation. This ensures that only permitted instances can use the reserved capacity.

        Parameters:
        instanceMatchCriteria - Indicates the type of instance launches that the Capacity Reservation accepts. The options include:

        • open - The Capacity Reservation accepts all instances that have matching attributes (instance type, platform, and Availability Zone). Instances that have matching attributes launch into the Capacity Reservation automatically without specifying any additional parameters.

        • targeted - The Capacity Reservation only accepts instances that have matching attributes (instance type, platform, and Availability Zone), and explicitly target the Capacity Reservation. This ensures that only permitted instances can use the reserved capacity.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        InstanceMatchCriteria, InstanceMatchCriteria
      • instanceMatchCriteria

        CapacityReservation.Builder instanceMatchCriteria​(InstanceMatchCriteria instanceMatchCriteria)

        Indicates the type of instance launches that the Capacity Reservation accepts. The options include:

        • open - The Capacity Reservation accepts all instances that have matching attributes (instance type, platform, and Availability Zone). Instances that have matching attributes launch into the Capacity Reservation automatically without specifying any additional parameters.

        • targeted - The Capacity Reservation only accepts instances that have matching attributes (instance type, platform, and Availability Zone), and explicitly target the Capacity Reservation. This ensures that only permitted instances can use the reserved capacity.

        Parameters:
        instanceMatchCriteria - Indicates the type of instance launches that the Capacity Reservation accepts. The options include:

        • open - The Capacity Reservation accepts all instances that have matching attributes (instance type, platform, and Availability Zone). Instances that have matching attributes launch into the Capacity Reservation automatically without specifying any additional parameters.

        • targeted - The Capacity Reservation only accepts instances that have matching attributes (instance type, platform, and Availability Zone), and explicitly target the Capacity Reservation. This ensures that only permitted instances can use the reserved capacity.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        InstanceMatchCriteria, InstanceMatchCriteria
      • createDate

        CapacityReservation.Builder createDate​(Instant createDate)

        The date and time at which the Capacity Reservation was created.

        Parameters:
        createDate - The date and time at which the Capacity Reservation was created.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

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

        Any tags assigned to the Capacity Reservation.

        Parameters:
        tags - Any tags assigned to the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

        CapacityReservation.Builder tags​(Tag... tags)

        Any tags assigned to the Capacity Reservation.

        Parameters:
        tags - Any tags assigned to the Capacity Reservation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • tags

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

        Any tags assigned to the Capacity Reservation.

        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)
      • outpostArn

        CapacityReservation.Builder outpostArn​(String outpostArn)

        The Amazon Resource Name (ARN) of the Outpost on which the Capacity Reservation was created.

        Parameters:
        outpostArn - The Amazon Resource Name (ARN) of the Outpost on which the Capacity Reservation was created.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • capacityReservationFleetId

        CapacityReservation.Builder capacityReservationFleetId​(String capacityReservationFleetId)

        The ID of the Capacity Reservation Fleet to which the Capacity Reservation belongs. Only valid for Capacity Reservations that were created by a Capacity Reservation Fleet.

        Parameters:
        capacityReservationFleetId - The ID of the Capacity Reservation Fleet to which the Capacity Reservation belongs. Only valid for Capacity Reservations that were created by a Capacity Reservation Fleet.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • capacityAllocations

        CapacityReservation.Builder capacityAllocations​(Collection<CapacityAllocation> capacityAllocations)

        Information about instance capacity usage.

        Parameters:
        capacityAllocations - Information about instance capacity usage.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • capacityAllocations

        CapacityReservation.Builder capacityAllocations​(CapacityAllocation... capacityAllocations)

        Information about instance capacity usage.

        Parameters:
        capacityAllocations - Information about instance capacity usage.
        Returns:
        Returns a reference to this object so that method calls can be chained together.