com.pulumi.aws.ec2.kotlin.inputs.FleetTargetCapacitySpecificationArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-kotlin Show documentation
Show all versions of pulumi-aws-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.aws.ec2.kotlin.inputs
import com.pulumi.aws.ec2.inputs.FleetTargetCapacitySpecificationArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
*
* @property defaultTargetCapacityType Default target capacity type. Valid values: `on-demand`, `spot`.
* @property onDemandTargetCapacity The number of On-Demand units to request.
* @property spotTargetCapacity The number of Spot units to request.
* @property targetCapacityUnitType The unit for the target capacity.
* If you specify `target_capacity_unit_type`, `instance_requirements` must be specified.
* @property totalTargetCapacity The number of units to request, filled using `default_target_capacity_type`.
*/
public data class FleetTargetCapacitySpecificationArgs(
public val defaultTargetCapacityType: Output,
public val onDemandTargetCapacity: Output? = null,
public val spotTargetCapacity: Output? = null,
public val targetCapacityUnitType: Output? = null,
public val totalTargetCapacity: Output,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.aws.ec2.inputs.FleetTargetCapacitySpecificationArgs =
com.pulumi.aws.ec2.inputs.FleetTargetCapacitySpecificationArgs.builder()
.defaultTargetCapacityType(defaultTargetCapacityType.applyValue({ args0 -> args0 }))
.onDemandTargetCapacity(onDemandTargetCapacity?.applyValue({ args0 -> args0 }))
.spotTargetCapacity(spotTargetCapacity?.applyValue({ args0 -> args0 }))
.targetCapacityUnitType(targetCapacityUnitType?.applyValue({ args0 -> args0 }))
.totalTargetCapacity(totalTargetCapacity.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [FleetTargetCapacitySpecificationArgs].
*/
@PulumiTagMarker
public class FleetTargetCapacitySpecificationArgsBuilder internal constructor() {
private var defaultTargetCapacityType: Output? = null
private var onDemandTargetCapacity: Output? = null
private var spotTargetCapacity: Output? = null
private var targetCapacityUnitType: Output? = null
private var totalTargetCapacity: Output? = null
/**
* @param value Default target capacity type. Valid values: `on-demand`, `spot`.
*/
@JvmName("iybcwnhthioorohg")
public suspend fun defaultTargetCapacityType(`value`: Output) {
this.defaultTargetCapacityType = value
}
/**
* @param value The number of On-Demand units to request.
*/
@JvmName("snpqhqrqagellbhl")
public suspend fun onDemandTargetCapacity(`value`: Output) {
this.onDemandTargetCapacity = value
}
/**
* @param value The number of Spot units to request.
*/
@JvmName("fivdscbxijqedjgv")
public suspend fun spotTargetCapacity(`value`: Output) {
this.spotTargetCapacity = value
}
/**
* @param value The unit for the target capacity.
* If you specify `target_capacity_unit_type`, `instance_requirements` must be specified.
*/
@JvmName("ccximvqbmqxlyxij")
public suspend fun targetCapacityUnitType(`value`: Output) {
this.targetCapacityUnitType = value
}
/**
* @param value The number of units to request, filled using `default_target_capacity_type`.
*/
@JvmName("wnxuisqgchnvhohm")
public suspend fun totalTargetCapacity(`value`: Output) {
this.totalTargetCapacity = value
}
/**
* @param value Default target capacity type. Valid values: `on-demand`, `spot`.
*/
@JvmName("xbtnrcxibtgvsbnq")
public suspend fun defaultTargetCapacityType(`value`: String) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.defaultTargetCapacityType = mapped
}
/**
* @param value The number of On-Demand units to request.
*/
@JvmName("trvslsotyrvawwbk")
public suspend fun onDemandTargetCapacity(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.onDemandTargetCapacity = mapped
}
/**
* @param value The number of Spot units to request.
*/
@JvmName("vyjusdghuvggfrkc")
public suspend fun spotTargetCapacity(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.spotTargetCapacity = mapped
}
/**
* @param value The unit for the target capacity.
* If you specify `target_capacity_unit_type`, `instance_requirements` must be specified.
*/
@JvmName("cdyavcwrnxhgewyc")
public suspend fun targetCapacityUnitType(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.targetCapacityUnitType = mapped
}
/**
* @param value The number of units to request, filled using `default_target_capacity_type`.
*/
@JvmName("idpydytgnxyyuxjw")
public suspend fun totalTargetCapacity(`value`: Int) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.totalTargetCapacity = mapped
}
internal fun build(): FleetTargetCapacitySpecificationArgs = FleetTargetCapacitySpecificationArgs(
defaultTargetCapacityType = defaultTargetCapacityType ?: throw
PulumiNullFieldException("defaultTargetCapacityType"),
onDemandTargetCapacity = onDemandTargetCapacity,
spotTargetCapacity = spotTargetCapacity,
targetCapacityUnitType = targetCapacityUnitType,
totalTargetCapacity = totalTargetCapacity ?: throw PulumiNullFieldException("totalTargetCapacity"),
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy