All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.awsnative.ec2.kotlin.inputs.SpotFleetTargetGroupsConfigArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 1.24.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.ec2.kotlin.inputs

import com.pulumi.awsnative.ec2.inputs.SpotFleetTargetGroupsConfigArgs.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 com.pulumi.kotlin.applySuspend
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property targetGroups One or more target groups.
 */
public data class SpotFleetTargetGroupsConfigArgs(
    public val targetGroups: Output>,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.ec2.inputs.SpotFleetTargetGroupsConfigArgs =
        com.pulumi.awsnative.ec2.inputs.SpotFleetTargetGroupsConfigArgs.builder()
            .targetGroups(
                targetGroups.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [SpotFleetTargetGroupsConfigArgs].
 */
@PulumiTagMarker
public class SpotFleetTargetGroupsConfigArgsBuilder internal constructor() {
    private var targetGroups: Output>? = null

    /**
     * @param value One or more target groups.
     */
    @JvmName("dtwdjyjtajiycivm")
    public suspend fun targetGroups(`value`: Output>) {
        this.targetGroups = value
    }

    @JvmName("sulcqeejmarwchcr")
    public suspend fun targetGroups(vararg values: Output) {
        this.targetGroups = Output.all(values.asList())
    }

    /**
     * @param values One or more target groups.
     */
    @JvmName("dflwagbgkspnoggl")
    public suspend fun targetGroups(values: List>) {
        this.targetGroups = Output.all(values)
    }

    /**
     * @param value One or more target groups.
     */
    @JvmName("clbvcqduhxhhpdhg")
    public suspend fun targetGroups(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.targetGroups = mapped
    }

    /**
     * @param argument One or more target groups.
     */
    @JvmName("enfhtbjvmkqesook")
    public suspend fun targetGroups(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            SpotFleetTargetGroupArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.targetGroups = mapped
    }

    /**
     * @param argument One or more target groups.
     */
    @JvmName("wkkpuofsrqcrhoed")
    public suspend fun targetGroups(vararg argument: suspend SpotFleetTargetGroupArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            SpotFleetTargetGroupArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.targetGroups = mapped
    }

    /**
     * @param argument One or more target groups.
     */
    @JvmName("wpvjpkkgamqlcdlr")
    public suspend fun targetGroups(argument: suspend SpotFleetTargetGroupArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(SpotFleetTargetGroupArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.targetGroups = mapped
    }

    /**
     * @param values One or more target groups.
     */
    @JvmName("jlakkfuetdtsslsb")
    public suspend fun targetGroups(vararg values: SpotFleetTargetGroupArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.targetGroups = mapped
    }

    internal fun build(): SpotFleetTargetGroupsConfigArgs = SpotFleetTargetGroupsConfigArgs(
        targetGroups = targetGroups ?: throw PulumiNullFieldException("targetGroups"),
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy