Class CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder
java.lang.Object
software.amazon.awscdk.cfnpropertymixins.services.ec2.CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnSpotFleetPropsMixin.SpotPlacementProperty>
- Enclosing interface:
CfnSpotFleetPropsMixin.SpotPlacementProperty
@Stability(Stable)
public static final class CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnSpotFleetPropsMixin.SpotPlacementProperty>
A builder for
CfnSpotFleetPropsMixin.SpotPlacementProperty-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionavailabilityZone(String availabilityZone) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getAvailabilityZone()availabilityZoneId(String availabilityZoneId) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getAvailabilityZoneId()build()Builds the configured instance.Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getGroupName()Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getTenancy()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
availabilityZone
@Stability(Stable) public CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder availabilityZone(String availabilityZone) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getAvailabilityZone()- Parameters:
availabilityZone- The Availability Zone. To specify multiple Availability Zones, separate them using commas; for example, "us-west-2a, us-west-2b".- Returns:
this
-
availabilityZoneId
@Stability(Stable) public CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder availabilityZoneId(String availabilityZoneId) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getAvailabilityZoneId()- Parameters:
availabilityZoneId- The ID of the Availability Zone. For example,use2-az1. [Spot Fleet only] To specify multiple Availability Zones, separate them using commas; for example, "use2-az1,use2-bz1".Either
AvailabilityZoneorAvailabilityZoneIdmust be specified in the request, but not both.- Returns:
this
-
groupName
@Stability(Stable) public CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder groupName(String groupName) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getGroupName()- Parameters:
groupName- The name of the placement group.- Returns:
this
-
tenancy
@Stability(Stable) public CfnSpotFleetPropsMixin.SpotPlacementProperty.Builder tenancy(String tenancy) Sets the value ofCfnSpotFleetPropsMixin.SpotPlacementProperty.getTenancy()- Parameters:
tenancy- The tenancy of the instance (if the instance is running in a VPC). An instance with a tenancy ofdedicatedruns on single-tenant hardware. Thehosttenancy is not supported for Spot Instances.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnSpotFleetPropsMixin.SpotPlacementProperty>- Returns:
- a new instance of
CfnSpotFleetPropsMixin.SpotPlacementProperty - Throws:
NullPointerException- if any required attribute was not provided
-