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

com.pulumi.awsnative.fis.kotlin.ExperimentTemplateArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.fis.kotlin

import com.pulumi.awsnative.fis.ExperimentTemplateArgs.builder
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateActionArgs
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateActionArgsBuilder
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateExperimentOptionsArgs
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateExperimentOptionsArgsBuilder
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateLogConfigurationArgs
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateLogConfigurationArgsBuilder
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateStopConditionArgs
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateStopConditionArgsBuilder
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateTargetArgs
import com.pulumi.awsnative.fis.kotlin.inputs.ExperimentTemplateTargetArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * Resource schema for AWS::FIS::ExperimentTemplate
 * ## Example Usage
 * ### Example
 * No Java example available.
 * @property actions The actions for the experiment.
 * @property description The description for the experiment template.
 * @property experimentOptions The experiment options for an experiment template.
 * @property logConfiguration The configuration for experiment logging.
 * @property roleArn The Amazon Resource Name (ARN) of an IAM role.
 * @property stopConditions The stop conditions for the experiment.
 * @property tags The tags for the experiment template.
 * @property targets The targets for the experiment.
 */
public data class ExperimentTemplateArgs(
    public val actions: Output>? = null,
    public val description: Output? = null,
    public val experimentOptions: Output? = null,
    public val logConfiguration: Output? = null,
    public val roleArn: Output? = null,
    public val stopConditions: Output>? = null,
    public val tags: Output>? = null,
    public val targets: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.fis.ExperimentTemplateArgs =
        com.pulumi.awsnative.fis.ExperimentTemplateArgs.builder()
            .actions(
                actions?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(
                            args0.value.let({ args0 ->
                                args0.toJava()
                            }),
                        )
                    }).toMap()
                }),
            )
            .description(description?.applyValue({ args0 -> args0 }))
            .experimentOptions(experimentOptions?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .logConfiguration(logConfiguration?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .roleArn(roleArn?.applyValue({ args0 -> args0 }))
            .stopConditions(
                stopConditions?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
            .targets(
                targets?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(
                            args0.value.let({ args0 ->
                                args0.toJava()
                            }),
                        )
                    }).toMap()
                }),
            ).build()
}

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

    private var description: Output? = null

    private var experimentOptions: Output? = null

    private var logConfiguration: Output? = null

    private var roleArn: Output? = null

    private var stopConditions: Output>? = null

    private var tags: Output>? = null

    private var targets: Output>? = null

    /**
     * @param value The actions for the experiment.
     */
    @JvmName("qucahqrntpxslsxc")
    public suspend fun actions(`value`: Output>) {
        this.actions = value
    }

    /**
     * @param value The description for the experiment template.
     */
    @JvmName("werfhifgkkrcewbh")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value The experiment options for an experiment template.
     */
    @JvmName("vtgcvvvfnxriefop")
    public suspend fun experimentOptions(`value`: Output) {
        this.experimentOptions = value
    }

    /**
     * @param value The configuration for experiment logging.
     */
    @JvmName("oxnqkecyxythbawt")
    public suspend fun logConfiguration(`value`: Output) {
        this.logConfiguration = value
    }

    /**
     * @param value The Amazon Resource Name (ARN) of an IAM role.
     */
    @JvmName("rhduhioebktktinr")
    public suspend fun roleArn(`value`: Output) {
        this.roleArn = value
    }

    /**
     * @param value The stop conditions for the experiment.
     */
    @JvmName("cgdbfnhlafbuymwi")
    public suspend fun stopConditions(`value`: Output>) {
        this.stopConditions = value
    }

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

    /**
     * @param values The stop conditions for the experiment.
     */
    @JvmName("sljhefvbxopooufe")
    public suspend fun stopConditions(values: List>) {
        this.stopConditions = Output.all(values)
    }

    /**
     * @param value The tags for the experiment template.
     */
    @JvmName("gxugaaqvuirasdoe")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value The targets for the experiment.
     */
    @JvmName("bqnsskjbfwdyvcch")
    public suspend fun targets(`value`: Output>) {
        this.targets = value
    }

    /**
     * @param value The actions for the experiment.
     */
    @JvmName("iefpxrfxxhfyeogx")
    public suspend fun actions(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.actions = mapped
    }

    /**
     * @param argument The actions for the experiment.
     */
    @JvmName("skdmkuqykfksuvgg")
    public suspend fun actions(vararg argument: Pair Unit>) {
        val toBeMapped = argument.toList().map { (left, right) ->
            left to
                ExperimentTemplateActionArgsBuilder().applySuspend { right() }.build()
        }.toMap()
        val mapped = of(toBeMapped)
        this.actions = mapped
    }

    /**
     * @param values The actions for the experiment.
     */
    @JvmName("xqeaarxcefrdgbny")
    public fun actions(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.actions = mapped
    }

    /**
     * @param value The description for the experiment template.
     */
    @JvmName("divcsfbrilbchrrx")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value The experiment options for an experiment template.
     */
    @JvmName("ruyesjcptdomdbsq")
    public suspend fun experimentOptions(`value`: ExperimentTemplateExperimentOptionsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.experimentOptions = mapped
    }

    /**
     * @param argument The experiment options for an experiment template.
     */
    @JvmName("aoxgkusnvsmfqwie")
    public suspend fun experimentOptions(argument: suspend ExperimentTemplateExperimentOptionsArgsBuilder.() -> Unit) {
        val toBeMapped = ExperimentTemplateExperimentOptionsArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.experimentOptions = mapped
    }

    /**
     * @param value The configuration for experiment logging.
     */
    @JvmName("ujdyawggvslymnwd")
    public suspend fun logConfiguration(`value`: ExperimentTemplateLogConfigurationArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.logConfiguration = mapped
    }

    /**
     * @param argument The configuration for experiment logging.
     */
    @JvmName("eakphnvhdoydbmua")
    public suspend fun logConfiguration(argument: suspend ExperimentTemplateLogConfigurationArgsBuilder.() -> Unit) {
        val toBeMapped = ExperimentTemplateLogConfigurationArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.logConfiguration = mapped
    }

    /**
     * @param value The Amazon Resource Name (ARN) of an IAM role.
     */
    @JvmName("altaodcybpcdfupn")
    public suspend fun roleArn(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.roleArn = mapped
    }

    /**
     * @param value The stop conditions for the experiment.
     */
    @JvmName("yfchftqofpercatf")
    public suspend fun stopConditions(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.stopConditions = mapped
    }

    /**
     * @param argument The stop conditions for the experiment.
     */
    @JvmName("nwgsvamaifbwmwls")
    public suspend fun stopConditions(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ExperimentTemplateStopConditionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.stopConditions = mapped
    }

    /**
     * @param argument The stop conditions for the experiment.
     */
    @JvmName("baqnofergqbffbnx")
    public suspend fun stopConditions(vararg argument: suspend ExperimentTemplateStopConditionArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ExperimentTemplateStopConditionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.stopConditions = mapped
    }

    /**
     * @param argument The stop conditions for the experiment.
     */
    @JvmName("dbbtwculbyxtjnic")
    public suspend fun stopConditions(argument: suspend ExperimentTemplateStopConditionArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ExperimentTemplateStopConditionArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.stopConditions = mapped
    }

    /**
     * @param values The stop conditions for the experiment.
     */
    @JvmName("kefuoqgybkuhhamg")
    public suspend fun stopConditions(vararg values: ExperimentTemplateStopConditionArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.stopConditions = mapped
    }

    /**
     * @param value The tags for the experiment template.
     */
    @JvmName("tqppfwdkchugxoyh")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values The tags for the experiment template.
     */
    @JvmName("rsfnhyyqayskvixu")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param value The targets for the experiment.
     */
    @JvmName("owbkgahwwlmusydo")
    public suspend fun targets(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.targets = mapped
    }

    /**
     * @param argument The targets for the experiment.
     */
    @JvmName("filktmcfjwfsgyxl")
    public suspend fun targets(vararg argument: Pair Unit>) {
        val toBeMapped = argument.toList().map { (left, right) ->
            left to
                ExperimentTemplateTargetArgsBuilder().applySuspend { right() }.build()
        }.toMap()
        val mapped = of(toBeMapped)
        this.targets = mapped
    }

    /**
     * @param values The targets for the experiment.
     */
    @JvmName("vhssuhbbpruekkej")
    public fun targets(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.targets = mapped
    }

    internal fun build(): ExperimentTemplateArgs = ExperimentTemplateArgs(
        actions = actions,
        description = description,
        experimentOptions = experimentOptions,
        logConfiguration = logConfiguration,
        roleArn = roleArn,
        stopConditions = stopConditions,
        tags = tags,
        targets = targets,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy