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

com.pulumi.awsnative.connect.kotlin.inputs.EvaluationFormSectionArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.awsnative.connect.kotlin.inputs

import com.pulumi.awsnative.connect.inputs.EvaluationFormSectionArgs.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.Double
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Information about a section from an evaluation form. A section can contain sections and/or questions. Evaluation forms can only contain sections and subsections (two level nesting).
 * @property instructions The instructions of the section.
 * @property items The items of the section.
 *   *Minimum*: 1
 * @property refId The identifier of the section. An identifier must be unique within the evaluation form.
 *   *Length Constraints*: Minimum length of 1. Maximum length of 40.
 * @property title The title of the section.
 *   *Length Constraints*: Minimum length of 1. Maximum length of 128.
 * @property weight The scoring weight of the section.
 *   *Minimum*: 0
 *   *Maximum*: 100
 */
public data class EvaluationFormSectionArgs(
    public val instructions: Output? = null,
    public val items: Output>? = null,
    public val refId: Output,
    public val title: Output,
    public val weight: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.connect.inputs.EvaluationFormSectionArgs =
        com.pulumi.awsnative.connect.inputs.EvaluationFormSectionArgs.builder()
            .instructions(instructions?.applyValue({ args0 -> args0 }))
            .items(items?.applyValue({ args0 -> args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) }) }))
            .refId(refId.applyValue({ args0 -> args0 }))
            .title(title.applyValue({ args0 -> args0 }))
            .weight(weight?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [EvaluationFormSectionArgs].
 */
@PulumiTagMarker
public class EvaluationFormSectionArgsBuilder internal constructor() {
    private var instructions: Output? = null

    private var items: Output>? = null

    private var refId: Output? = null

    private var title: Output? = null

    private var weight: Output? = null

    /**
     * @param value The instructions of the section.
     */
    @JvmName("ahgloehdnnhhbaxn")
    public suspend fun instructions(`value`: Output) {
        this.instructions = value
    }

    /**
     * @param value The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("okjlcrarnpbcncki")
    public suspend fun items(`value`: Output>) {
        this.items = value
    }

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

    /**
     * @param values The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("jdubbwsboqmfeebp")
    public suspend fun items(values: List>) {
        this.items = Output.all(values)
    }

    /**
     * @param value The identifier of the section. An identifier must be unique within the evaluation form.
     *   *Length Constraints*: Minimum length of 1. Maximum length of 40.
     */
    @JvmName("iowpjbtsfnlsimit")
    public suspend fun refId(`value`: Output) {
        this.refId = value
    }

    /**
     * @param value The title of the section.
     *   *Length Constraints*: Minimum length of 1. Maximum length of 128.
     */
    @JvmName("phwatxkudhsheciu")
    public suspend fun title(`value`: Output) {
        this.title = value
    }

    /**
     * @param value The scoring weight of the section.
     *   *Minimum*: 0
     *   *Maximum*: 100
     */
    @JvmName("wiiiwwvelrneqyps")
    public suspend fun weight(`value`: Output) {
        this.weight = value
    }

    /**
     * @param value The instructions of the section.
     */
    @JvmName("focarbuadcuheees")
    public suspend fun instructions(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.instructions = mapped
    }

    /**
     * @param value The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("dbavqyjtrjfcolxu")
    public suspend fun items(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.items = mapped
    }

    /**
     * @param argument The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("moyusoukogrgklnk")
    public suspend fun items(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            EvaluationFormItemArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.items = mapped
    }

    /**
     * @param argument The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("yhgdyevrngkvlcgl")
    public suspend fun items(vararg argument: suspend EvaluationFormItemArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            EvaluationFormItemArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.items = mapped
    }

    /**
     * @param argument The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("louuvbohvrjkvqfd")
    public suspend fun items(argument: suspend EvaluationFormItemArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(EvaluationFormItemArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.items = mapped
    }

    /**
     * @param values The items of the section.
     *   *Minimum*: 1
     */
    @JvmName("hjnxeurgvybrcwrb")
    public suspend fun items(vararg values: EvaluationFormItemArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.items = mapped
    }

    /**
     * @param value The identifier of the section. An identifier must be unique within the evaluation form.
     *   *Length Constraints*: Minimum length of 1. Maximum length of 40.
     */
    @JvmName("lcunvljpvvoiibxv")
    public suspend fun refId(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.refId = mapped
    }

    /**
     * @param value The title of the section.
     *   *Length Constraints*: Minimum length of 1. Maximum length of 128.
     */
    @JvmName("pphdxioqluakpwkd")
    public suspend fun title(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.title = mapped
    }

    /**
     * @param value The scoring weight of the section.
     *   *Minimum*: 0
     *   *Maximum*: 100
     */
    @JvmName("utahdfxocbkeurit")
    public suspend fun weight(`value`: Double?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.weight = mapped
    }

    internal fun build(): EvaluationFormSectionArgs = EvaluationFormSectionArgs(
        instructions = instructions,
        items = items,
        refId = refId ?: throw PulumiNullFieldException("refId"),
        title = title ?: throw PulumiNullFieldException("title"),
        weight = weight,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy