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

com.pulumi.azure.network.kotlin.inputs.FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azure.network.kotlin.inputs

import com.pulumi.azure.network.inputs.FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs.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.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property action The action to take for the NAT rules in this collection. Currently, the only possible value is `Dnat`.
 * @property name The name which should be used for this NAT rule collection.
 * @property priority The priority of the NAT rule collection. The range is `100` - `65000`.
 * @property rules A `nat_rule` block as defined below.
 */
public data class FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs(
    public val action: Output,
    public val name: Output,
    public val priority: Output,
    public val rules: Output>,
) :
    ConvertibleToJava {
    override fun toJava():
        com.pulumi.azure.network.inputs.FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs =
        com.pulumi.azure.network.inputs.FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs.builder()
            .action(action.applyValue({ args0 -> args0 }))
            .name(name.applyValue({ args0 -> args0 }))
            .priority(priority.applyValue({ args0 -> args0 }))
            .rules(
                rules.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs].
 */
@PulumiTagMarker
public class FirewallPolicyRuleCollectionGroupNatRuleCollectionArgsBuilder internal constructor() {
    private var action: Output? = null

    private var name: Output? = null

    private var priority: Output? = null

    private var rules: Output>? =
        null

    /**
     * @param value The action to take for the NAT rules in this collection. Currently, the only possible value is `Dnat`.
     */
    @JvmName("ecnvtlshhdaoeuwf")
    public suspend fun action(`value`: Output) {
        this.action = value
    }

    /**
     * @param value The name which should be used for this NAT rule collection.
     */
    @JvmName("jpmlstysmwjxtpot")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The priority of the NAT rule collection. The range is `100` - `65000`.
     */
    @JvmName("yfwxpkvimdpnruhj")
    public suspend fun priority(`value`: Output) {
        this.priority = value
    }

    /**
     * @param value A `nat_rule` block as defined below.
     */
    @JvmName("srtavecpgdxnccui")
    public suspend
    fun rules(`value`: Output>) {
        this.rules = value
    }

    @JvmName("oorhgdvuksuskusi")
    public suspend fun rules(
        vararg
        values: Output,
    ) {
        this.rules = Output.all(values.asList())
    }

    /**
     * @param values A `nat_rule` block as defined below.
     */
    @JvmName("vpgestplgxipuvde")
    public suspend
    fun rules(values: List>) {
        this.rules = Output.all(values)
    }

    /**
     * @param value The action to take for the NAT rules in this collection. Currently, the only possible value is `Dnat`.
     */
    @JvmName("xkcdwwgvskqdveim")
    public suspend fun action(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.action = mapped
    }

    /**
     * @param value The name which should be used for this NAT rule collection.
     */
    @JvmName("cjygfxdhffomvhyy")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The priority of the NAT rule collection. The range is `100` - `65000`.
     */
    @JvmName("nwijeudxticgyiep")
    public suspend fun priority(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.priority = mapped
    }

    /**
     * @param value A `nat_rule` block as defined below.
     */
    @JvmName("leoumsmqdsnqahdb")
    public suspend
    fun rules(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.rules = mapped
    }

    /**
     * @param argument A `nat_rule` block as defined below.
     */
    @JvmName("qtmqqwkvoesyfsdv")
    public suspend
    fun rules(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.rules = mapped
    }

    /**
     * @param argument A `nat_rule` block as defined below.
     */
    @JvmName("ghknrjyqwwmlxbxk")
    public suspend fun rules(
        vararg
        argument: suspend FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgsBuilder.() -> Unit,
    ) {
        val toBeMapped = argument.toList().map {
            FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.rules = mapped
    }

    /**
     * @param argument A `nat_rule` block as defined below.
     */
    @JvmName("pnjjjqbmsfckvorw")
    public suspend
    fun rules(argument: suspend FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgsBuilder().applySuspend {
                    argument()
                }.build(),
            )
        val mapped = of(toBeMapped)
        this.rules = mapped
    }

    /**
     * @param values A `nat_rule` block as defined below.
     */
    @JvmName("ptltpnwiuqxkedjd")
    public suspend fun rules(
        vararg
        values: FirewallPolicyRuleCollectionGroupNatRuleCollectionRuleArgs,
    ) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.rules = mapped
    }

    internal fun build(): FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs =
        FirewallPolicyRuleCollectionGroupNatRuleCollectionArgs(
            action = action ?: throw PulumiNullFieldException("action"),
            name = name ?: throw PulumiNullFieldException("name"),
            priority = priority ?: throw PulumiNullFieldException("priority"),
            rules = rules ?: throw PulumiNullFieldException("rules"),
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy