com.pulumi.aws.ec2.inputs.GetCapacityBlockOfferingPlainArgs Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aws Show documentation
Show all versions of aws Show documentation
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.aws.ec2.inputs;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
public final class GetCapacityBlockOfferingPlainArgs extends com.pulumi.resources.InvokeArgs {
public static final GetCapacityBlockOfferingPlainArgs Empty = new GetCapacityBlockOfferingPlainArgs();
/**
* The amount of time of the Capacity Block reservation in hours.
*
*/
@Import(name="capacityDurationHours", required=true)
private Integer capacityDurationHours;
/**
* @return The amount of time of the Capacity Block reservation in hours.
*
*/
public Integer capacityDurationHours() {
return this.capacityDurationHours;
}
/**
* The date and time at which the Capacity Block Reservation expires. When a Capacity Reservation expires, the reserved capacity is released and you can no longer launch instances into it. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
*/
@Import(name="endDateRange")
private @Nullable String endDateRange;
/**
* @return The date and time at which the Capacity Block Reservation expires. When a Capacity Reservation expires, the reserved capacity is released and you can no longer launch instances into it. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
*/
public Optional endDateRange() {
return Optional.ofNullable(this.endDateRange);
}
/**
* The number of instances for which to reserve capacity.
*
*/
@Import(name="instanceCount", required=true)
private Integer instanceCount;
/**
* @return The number of instances for which to reserve capacity.
*
*/
public Integer instanceCount() {
return this.instanceCount;
}
/**
* The instance type for which to reserve capacity.
*
*/
@Import(name="instanceType", required=true)
private String instanceType;
/**
* @return The instance type for which to reserve capacity.
*
*/
public String instanceType() {
return this.instanceType;
}
/**
* The date and time at which the Capacity Block Reservation starts. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
*/
@Import(name="startDateRange")
private @Nullable String startDateRange;
/**
* @return The date and time at which the Capacity Block Reservation starts. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
*/
public Optional startDateRange() {
return Optional.ofNullable(this.startDateRange);
}
private GetCapacityBlockOfferingPlainArgs() {}
private GetCapacityBlockOfferingPlainArgs(GetCapacityBlockOfferingPlainArgs $) {
this.capacityDurationHours = $.capacityDurationHours;
this.endDateRange = $.endDateRange;
this.instanceCount = $.instanceCount;
this.instanceType = $.instanceType;
this.startDateRange = $.startDateRange;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(GetCapacityBlockOfferingPlainArgs defaults) {
return new Builder(defaults);
}
public static final class Builder {
private GetCapacityBlockOfferingPlainArgs $;
public Builder() {
$ = new GetCapacityBlockOfferingPlainArgs();
}
public Builder(GetCapacityBlockOfferingPlainArgs defaults) {
$ = new GetCapacityBlockOfferingPlainArgs(Objects.requireNonNull(defaults));
}
/**
* @param capacityDurationHours The amount of time of the Capacity Block reservation in hours.
*
* @return builder
*
*/
public Builder capacityDurationHours(Integer capacityDurationHours) {
$.capacityDurationHours = capacityDurationHours;
return this;
}
/**
* @param endDateRange The date and time at which the Capacity Block Reservation expires. When a Capacity Reservation expires, the reserved capacity is released and you can no longer launch instances into it. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
* @return builder
*
*/
public Builder endDateRange(@Nullable String endDateRange) {
$.endDateRange = endDateRange;
return this;
}
/**
* @param instanceCount The number of instances for which to reserve capacity.
*
* @return builder
*
*/
public Builder instanceCount(Integer instanceCount) {
$.instanceCount = instanceCount;
return this;
}
/**
* @param instanceType The instance type for which to reserve capacity.
*
* @return builder
*
*/
public Builder instanceType(String instanceType) {
$.instanceType = instanceType;
return this;
}
/**
* @param startDateRange The date and time at which the Capacity Block Reservation starts. Valid values: [RFC3339 time string](https://tools.ietf.org/html/rfc3339#section-5.8) (`YYYY-MM-DDTHH:MM:SSZ`)
*
* @return builder
*
*/
public Builder startDateRange(@Nullable String startDateRange) {
$.startDateRange = startDateRange;
return this;
}
public GetCapacityBlockOfferingPlainArgs build() {
if ($.capacityDurationHours == null) {
throw new MissingRequiredPropertyException("GetCapacityBlockOfferingPlainArgs", "capacityDurationHours");
}
if ($.instanceCount == null) {
throw new MissingRequiredPropertyException("GetCapacityBlockOfferingPlainArgs", "instanceCount");
}
if ($.instanceType == null) {
throw new MissingRequiredPropertyException("GetCapacityBlockOfferingPlainArgs", "instanceType");
}
return $;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy