Class CfnLaunchTemplate.CapacityReservationTargetProperty.Builder
java.lang.Object
software.amazon.awscdk.services.ec2.CfnLaunchTemplate.CapacityReservationTargetProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnLaunchTemplate.CapacityReservationTargetProperty>
- Enclosing interface:
CfnLaunchTemplate.CapacityReservationTargetProperty
@Stability(Stable)
public static final class CfnLaunchTemplate.CapacityReservationTargetProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnLaunchTemplate.CapacityReservationTargetProperty>
A builder for
CfnLaunchTemplate.CapacityReservationTargetProperty
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.capacityReservationId
(String capacityReservationId) capacityReservationResourceGroupArn
(String capacityReservationResourceGroupArn)
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
capacityReservationId
@Stability(Stable) public CfnLaunchTemplate.CapacityReservationTargetProperty.Builder capacityReservationId(String capacityReservationId) - Parameters:
capacityReservationId
- The ID of the Capacity Reservation in which to run the instance.- Returns:
this
-
capacityReservationResourceGroupArn
@Stability(Stable) public CfnLaunchTemplate.CapacityReservationTargetProperty.Builder capacityReservationResourceGroupArn(String capacityReservationResourceGroupArn) Sets the value ofCfnLaunchTemplate.CapacityReservationTargetProperty.getCapacityReservationResourceGroupArn()
- Parameters:
capacityReservationResourceGroupArn
- The ARN of the Capacity Reservation resource group in which to run the instance.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnLaunchTemplate.CapacityReservationTargetProperty>
- Returns:
- a new instance of
CfnLaunchTemplate.CapacityReservationTargetProperty
- Throws:
NullPointerException
- if any required attribute was not provided
-