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

com.pulumi.azurenative.cdn.kotlin.inputs.UrlRewriteActionArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.cdn.kotlin.inputs

import com.pulumi.azurenative.cdn.inputs.UrlRewriteActionArgs.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.jvm.JvmName

/**
 * Defines the url rewrite action for the delivery rule.
 * @property name The name of the action for the delivery rule.
 * Expected value is 'UrlRewrite'.
 * @property parameters Defines the parameters for the action.
 */
public data class UrlRewriteActionArgs(
    public val name: Output,
    public val parameters: Output,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.cdn.inputs.UrlRewriteActionArgs =
        com.pulumi.azurenative.cdn.inputs.UrlRewriteActionArgs.builder()
            .name(name.applyValue({ args0 -> args0 }))
            .parameters(parameters.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}

/**
 * Builder for [UrlRewriteActionArgs].
 */
@PulumiTagMarker
public class UrlRewriteActionArgsBuilder internal constructor() {
    private var name: Output? = null

    private var parameters: Output? = null

    /**
     * @param value The name of the action for the delivery rule.
     * Expected value is 'UrlRewrite'.
     */
    @JvmName("qqmpruqbnujgolvf")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value Defines the parameters for the action.
     */
    @JvmName("ciogtfydylilwphd")
    public suspend fun parameters(`value`: Output) {
        this.parameters = value
    }

    /**
     * @param value The name of the action for the delivery rule.
     * Expected value is 'UrlRewrite'.
     */
    @JvmName("oqbmkfrcesjuiqrw")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value Defines the parameters for the action.
     */
    @JvmName("wtydolgogkhnougn")
    public suspend fun parameters(`value`: UrlRewriteActionParametersArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.parameters = mapped
    }

    /**
     * @param argument Defines the parameters for the action.
     */
    @JvmName("aubgdgaradrxayav")
    public suspend fun parameters(argument: suspend UrlRewriteActionParametersArgsBuilder.() -> Unit) {
        val toBeMapped = UrlRewriteActionParametersArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.parameters = mapped
    }

    internal fun build(): UrlRewriteActionArgs = UrlRewriteActionArgs(
        name = name ?: throw PulumiNullFieldException("name"),
        parameters = parameters ?: throw PulumiNullFieldException("parameters"),
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy