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

com.pulumi.azurenative.app.kotlin.BuilderArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.app.kotlin

import com.pulumi.azurenative.app.BuilderArgs.builder
import com.pulumi.azurenative.app.kotlin.inputs.ContainerRegistryArgs
import com.pulumi.azurenative.app.kotlin.inputs.ContainerRegistryArgsBuilder
import com.pulumi.azurenative.app.kotlin.inputs.ManagedServiceIdentityArgs
import com.pulumi.azurenative.app.kotlin.inputs.ManagedServiceIdentityArgsBuilder
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

/**
 * Information about the SourceToCloud builder resource.
 * Azure REST API version: 2023-08-01-preview.
 * Other available API versions: 2023-11-02-preview, 2024-02-02-preview.
 * ## Import
 * An existing resource can be imported using its type token, name, and identifier, e.g.
 * ```sh
 * $ pulumi import azure-native:app:Builder testBuilder /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/builders/{builderName}
 * ```
 * @property builderName The name of the builder.
 * @property containerRegistries List of mappings of container registries and the managed identity used to connect to it.
 * @property environmentId Resource ID of the container apps environment that the builder is associated with.
 * @property identity The managed service identities assigned to this resource.
 * @property location The geo-location where the resource lives
 * @property resourceGroupName The name of the resource group. The name is case insensitive.
 * @property tags Resource tags.
 */
public data class BuilderArgs(
    public val builderName: Output? = null,
    public val containerRegistries: Output>? = null,
    public val environmentId: Output? = null,
    public val identity: Output? = null,
    public val location: Output? = null,
    public val resourceGroupName: Output? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.app.BuilderArgs =
        com.pulumi.azurenative.app.BuilderArgs.builder()
            .builderName(builderName?.applyValue({ args0 -> args0 }))
            .containerRegistries(
                containerRegistries?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .environmentId(environmentId?.applyValue({ args0 -> args0 }))
            .identity(identity?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .location(location?.applyValue({ args0 -> args0 }))
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [BuilderArgs].
 */
@PulumiTagMarker
public class BuilderArgsBuilder internal constructor() {
    private var builderName: Output? = null

    private var containerRegistries: Output>? = null

    private var environmentId: Output? = null

    private var identity: Output? = null

    private var location: Output? = null

    private var resourceGroupName: Output? = null

    private var tags: Output>? = null

    /**
     * @param value The name of the builder.
     */
    @JvmName("xjvxrmomvybpqmvs")
    public suspend fun builderName(`value`: Output) {
        this.builderName = value
    }

    /**
     * @param value List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("lqpidecpapbyfmjr")
    public suspend fun containerRegistries(`value`: Output>) {
        this.containerRegistries = value
    }

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

    /**
     * @param values List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("gkkbicwskixdawdj")
    public suspend fun containerRegistries(values: List>) {
        this.containerRegistries = Output.all(values)
    }

    /**
     * @param value Resource ID of the container apps environment that the builder is associated with.
     */
    @JvmName("updphwmdvdsejejq")
    public suspend fun environmentId(`value`: Output) {
        this.environmentId = value
    }

    /**
     * @param value The managed service identities assigned to this resource.
     */
    @JvmName("iwojjtptrkefhucf")
    public suspend fun identity(`value`: Output) {
        this.identity = value
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("icjfuyqcoevqmvwh")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value The name of the resource group. The name is case insensitive.
     */
    @JvmName("bplhnguhmfvospju")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("bvbregmojaexyloj")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

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

    /**
     * @param value List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("sauxxhnnfwbbtxcf")
    public suspend fun containerRegistries(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.containerRegistries = mapped
    }

    /**
     * @param argument List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("qbbfbdioimqkuprj")
    public suspend fun containerRegistries(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ContainerRegistryArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.containerRegistries = mapped
    }

    /**
     * @param argument List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("nepbvgbdvfscsqfv")
    public suspend fun containerRegistries(vararg argument: suspend ContainerRegistryArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ContainerRegistryArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.containerRegistries = mapped
    }

    /**
     * @param argument List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("alfbuduywtjxxvpl")
    public suspend fun containerRegistries(argument: suspend ContainerRegistryArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(ContainerRegistryArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.containerRegistries = mapped
    }

    /**
     * @param values List of mappings of container registries and the managed identity used to connect to it.
     */
    @JvmName("amrbavcypuxkhlhn")
    public suspend fun containerRegistries(vararg values: ContainerRegistryArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.containerRegistries = mapped
    }

    /**
     * @param value Resource ID of the container apps environment that the builder is associated with.
     */
    @JvmName("bexjwnnjrxlycdok")
    public suspend fun environmentId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.environmentId = mapped
    }

    /**
     * @param value The managed service identities assigned to this resource.
     */
    @JvmName("jabhofdeabmxgnat")
    public suspend fun identity(`value`: ManagedServiceIdentityArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.identity = mapped
    }

    /**
     * @param argument The managed service identities assigned to this resource.
     */
    @JvmName("lpywryyuoxkkgvyl")
    public suspend fun identity(argument: suspend ManagedServiceIdentityArgsBuilder.() -> Unit) {
        val toBeMapped = ManagedServiceIdentityArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.identity = mapped
    }

    /**
     * @param value The geo-location where the resource lives
     */
    @JvmName("krijkrmnqsgpypfh")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value The name of the resource group. The name is case insensitive.
     */
    @JvmName("aexkhwvjojgsqeqe")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value Resource tags.
     */
    @JvmName("epskaexatkklebbe")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values Resource tags.
     */
    @JvmName("hxbsximcvkwrhqca")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): BuilderArgs = BuilderArgs(
        builderName = builderName,
        containerRegistries = containerRegistries,
        environmentId = environmentId,
        identity = identity,
        location = location,
        resourceGroupName = resourceGroupName,
        tags = tags,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy