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

com.pulumi.gcp.accesscontextmanager.kotlin.inputs.AccessLevelsAccessLevelBasicArgs.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: 8.10.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.accesscontextmanager.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.accesscontextmanager.inputs.AccessLevelsAccessLevelBasicArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property combiningFunction How the conditions list should be combined to determine if a request
 * is granted this AccessLevel. If AND is used, each Condition in
 * conditions must be satisfied for the AccessLevel to be applied. If
 * OR is used, at least one Condition in conditions must be satisfied
 * for the AccessLevel to be applied.
 * Default value is `AND`.
 * Possible values are: `AND`, `OR`.
 * @property conditions A set of requirements for the AccessLevel to be granted.
 * Structure is documented below.
 */
public data class AccessLevelsAccessLevelBasicArgs(
    public val combiningFunction: Output? = null,
    public val conditions: Output>,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.accesscontextmanager.inputs.AccessLevelsAccessLevelBasicArgs = com.pulumi.gcp.accesscontextmanager.inputs.AccessLevelsAccessLevelBasicArgs.builder()
        .combiningFunction(combiningFunction?.applyValue({ args0 -> args0 }))
        .conditions(
            conditions.applyValue({ args0 ->
                args0.map({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                })
            }),
        ).build()
}

/**
 * Builder for [AccessLevelsAccessLevelBasicArgs].
 */
@PulumiTagMarker
public class AccessLevelsAccessLevelBasicArgsBuilder internal constructor() {
    private var combiningFunction: Output? = null

    private var conditions: Output>? = null

    /**
     * @param value How the conditions list should be combined to determine if a request
     * is granted this AccessLevel. If AND is used, each Condition in
     * conditions must be satisfied for the AccessLevel to be applied. If
     * OR is used, at least one Condition in conditions must be satisfied
     * for the AccessLevel to be applied.
     * Default value is `AND`.
     * Possible values are: `AND`, `OR`.
     */
    @JvmName("fynosqyntltodvri")
    public suspend fun combiningFunction(`value`: Output) {
        this.combiningFunction = value
    }

    /**
     * @param value A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("scysutnutyghjjun")
    public suspend fun conditions(`value`: Output>) {
        this.conditions = value
    }

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

    /**
     * @param values A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("gxegqlunsohiqoks")
    public suspend fun conditions(values: List>) {
        this.conditions = Output.all(values)
    }

    /**
     * @param value How the conditions list should be combined to determine if a request
     * is granted this AccessLevel. If AND is used, each Condition in
     * conditions must be satisfied for the AccessLevel to be applied. If
     * OR is used, at least one Condition in conditions must be satisfied
     * for the AccessLevel to be applied.
     * Default value is `AND`.
     * Possible values are: `AND`, `OR`.
     */
    @JvmName("fftyocyrrapphlqw")
    public suspend fun combiningFunction(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.combiningFunction = mapped
    }

    /**
     * @param value A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("xsyljbyxrbjalokj")
    public suspend fun conditions(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.conditions = mapped
    }

    /**
     * @param argument A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("qhbstoqfucduimqk")
    public suspend fun conditions(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            AccessLevelsAccessLevelBasicConditionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param argument A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("fumpkqcgmkldfxoa")
    public suspend fun conditions(vararg argument: suspend AccessLevelsAccessLevelBasicConditionArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            AccessLevelsAccessLevelBasicConditionArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param argument A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("npmwrlymusnrvwyt")
    public suspend fun conditions(argument: suspend AccessLevelsAccessLevelBasicConditionArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            AccessLevelsAccessLevelBasicConditionArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.conditions = mapped
    }

    /**
     * @param values A set of requirements for the AccessLevel to be granted.
     * Structure is documented below.
     */
    @JvmName("omtyfdnhnvdehxqa")
    public suspend fun conditions(vararg values: AccessLevelsAccessLevelBasicConditionArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.conditions = mapped
    }

    internal fun build(): AccessLevelsAccessLevelBasicArgs = AccessLevelsAccessLevelBasicArgs(
        combiningFunction = combiningFunction,
        conditions = conditions ?: throw PulumiNullFieldException("conditions"),
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy