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

com.pulumi.azure.network.kotlin.inputs.ApplicationGatewayRewriteRuleSetArgs.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: 6.14.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

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

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

/**
 *
 * @property id The ID of the Rewrite Rule Set
 * @property name Unique name of the rewrite rule set block
 * @property rewriteRules One or more `rewrite_rule` blocks as defined below.
 */
public data class ApplicationGatewayRewriteRuleSetArgs(
    public val id: Output? = null,
    public val name: Output,
    public val rewriteRules: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.network.inputs.ApplicationGatewayRewriteRuleSetArgs =
        com.pulumi.azure.network.inputs.ApplicationGatewayRewriteRuleSetArgs.builder()
            .id(id?.applyValue({ args0 -> args0 }))
            .name(name.applyValue({ args0 -> args0 }))
            .rewriteRules(
                rewriteRules?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [ApplicationGatewayRewriteRuleSetArgs].
 */
@PulumiTagMarker
public class ApplicationGatewayRewriteRuleSetArgsBuilder internal constructor() {
    private var id: Output? = null

    private var name: Output? = null

    private var rewriteRules: Output>? = null

    /**
     * @param value The ID of the Rewrite Rule Set
     */
    @JvmName("lvtuntripijkuvvr")
    public suspend fun id(`value`: Output) {
        this.id = value
    }

    /**
     * @param value Unique name of the rewrite rule set block
     */
    @JvmName("sbmptudqkbtbrmij")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("wpgddskykcrlkaim")
    public suspend
    fun rewriteRules(`value`: Output>) {
        this.rewriteRules = value
    }

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

    /**
     * @param values One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("iywubdqwcvwaakur")
    public suspend
    fun rewriteRules(values: List>) {
        this.rewriteRules = Output.all(values)
    }

    /**
     * @param value The ID of the Rewrite Rule Set
     */
    @JvmName("bqevilnjufhibmfh")
    public suspend fun id(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.id = mapped
    }

    /**
     * @param value Unique name of the rewrite rule set block
     */
    @JvmName("stsnqrtrxquslbox")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("cpqquewjmauypdmj")
    public suspend fun rewriteRules(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.rewriteRules = mapped
    }

    /**
     * @param argument One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("olndsqomdchcqokk")
    public suspend
    fun rewriteRules(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ApplicationGatewayRewriteRuleSetRewriteRuleArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.rewriteRules = mapped
    }

    /**
     * @param argument One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("hkhxpthflxbfmpwa")
    public suspend fun rewriteRules(
        vararg
        argument: suspend ApplicationGatewayRewriteRuleSetRewriteRuleArgsBuilder.() -> Unit,
    ) {
        val toBeMapped = argument.toList().map {
            ApplicationGatewayRewriteRuleSetRewriteRuleArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.rewriteRules = mapped
    }

    /**
     * @param argument One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("nuiqjtalhagbibog")
    public suspend
    fun rewriteRules(argument: suspend ApplicationGatewayRewriteRuleSetRewriteRuleArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ApplicationGatewayRewriteRuleSetRewriteRuleArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.rewriteRules = mapped
    }

    /**
     * @param values One or more `rewrite_rule` blocks as defined below.
     */
    @JvmName("mjmnevscmtecjjxg")
    public suspend fun rewriteRules(vararg values: ApplicationGatewayRewriteRuleSetRewriteRuleArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.rewriteRules = mapped
    }

    internal fun build(): ApplicationGatewayRewriteRuleSetArgs = ApplicationGatewayRewriteRuleSetArgs(
        id = id,
        name = name ?: throw PulumiNullFieldException("name"),
        rewriteRules = rewriteRules,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy