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

com.pulumi.awsnative.lex.kotlin.inputs.BotCustomVocabularyArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.awsnative.lex.kotlin.inputs

import com.pulumi.awsnative.lex.inputs.BotCustomVocabularyArgs.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

/**
 * A custom vocabulary is a list of specific phrases that you want Amazon Lex V2 to recognize in the audio input.
 * @property customVocabularyItems Specifies a list of words that you expect to be used during a conversation with your bot.
 */
public data class BotCustomVocabularyArgs(
    public val customVocabularyItems: Output>,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.lex.inputs.BotCustomVocabularyArgs =
        com.pulumi.awsnative.lex.inputs.BotCustomVocabularyArgs.builder()
            .customVocabularyItems(
                customVocabularyItems.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            ).build()
}

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

    /**
     * @param value Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("nbesvaxrtbdsseid")
    public suspend fun customVocabularyItems(`value`: Output>) {
        this.customVocabularyItems = value
    }

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

    /**
     * @param values Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("anntfxjnoxtvmrak")
    public suspend fun customVocabularyItems(values: List>) {
        this.customVocabularyItems = Output.all(values)
    }

    /**
     * @param value Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("pegadtjveypmhrko")
    public suspend fun customVocabularyItems(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.customVocabularyItems = mapped
    }

    /**
     * @param argument Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("yucsmwgiekikyoxe")
    public suspend fun customVocabularyItems(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            BotCustomVocabularyItemArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.customVocabularyItems = mapped
    }

    /**
     * @param argument Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("yjdvfwgwtfxujhmm")
    public suspend fun customVocabularyItems(vararg argument: suspend BotCustomVocabularyItemArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            BotCustomVocabularyItemArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.customVocabularyItems = mapped
    }

    /**
     * @param argument Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("txvaxewvvpwkrhtb")
    public suspend fun customVocabularyItems(argument: suspend BotCustomVocabularyItemArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            BotCustomVocabularyItemArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.customVocabularyItems = mapped
    }

    /**
     * @param values Specifies a list of words that you expect to be used during a conversation with your bot.
     */
    @JvmName("fhhgeclwcrbbxjpj")
    public suspend fun customVocabularyItems(vararg values: BotCustomVocabularyItemArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.customVocabularyItems = mapped
    }

    internal fun build(): BotCustomVocabularyArgs = BotCustomVocabularyArgs(
        customVocabularyItems = customVocabularyItems ?: throw
            PulumiNullFieldException("customVocabularyItems"),
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy