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

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

package com.pulumi.gcp.networkservices.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.networkservices.inputs.EdgeCacheServiceRoutingPathMatcherArgs.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 description A human-readable description of the resource.
 * @property name The name to which this PathMatcher is referred by the HostRule.
 * @property routeRules The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
 * Structure is documented below.
 */
public data class EdgeCacheServiceRoutingPathMatcherArgs(
    public val description: Output? = null,
    public val name: Output,
    public val routeRules: Output>,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.networkservices.inputs.EdgeCacheServiceRoutingPathMatcherArgs =
        com.pulumi.gcp.networkservices.inputs.EdgeCacheServiceRoutingPathMatcherArgs.builder()
            .description(description?.applyValue({ args0 -> args0 }))
            .name(name.applyValue({ args0 -> args0 }))
            .routeRules(
                routeRules.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [EdgeCacheServiceRoutingPathMatcherArgs].
 */
@PulumiTagMarker
public class EdgeCacheServiceRoutingPathMatcherArgsBuilder internal constructor() {
    private var description: Output? = null

    private var name: Output? = null

    private var routeRules: Output>? = null

    /**
     * @param value A human-readable description of the resource.
     */
    @JvmName("vhccwhqjoqajvnpa")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value The name to which this PathMatcher is referred by the HostRule.
     */
    @JvmName("wevhhmjlxuuurpsx")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("bokbupcolsenskbs")
    public suspend fun routeRules(`value`: Output>) {
        this.routeRules = value
    }

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

    /**
     * @param values The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("cfmkfahlepwmjbtk")
    public suspend fun routeRules(values: List>) {
        this.routeRules = Output.all(values)
    }

    /**
     * @param value A human-readable description of the resource.
     */
    @JvmName("gwuufuucoebkbova")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value The name to which this PathMatcher is referred by the HostRule.
     */
    @JvmName("fwokoldcmakjmvja")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("ithjxjsycmmendhf")
    public suspend fun routeRules(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.routeRules = mapped
    }

    /**
     * @param argument The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("oyadwgjaqfypmtbe")
    public suspend fun routeRules(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            EdgeCacheServiceRoutingPathMatcherRouteRuleArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.routeRules = mapped
    }

    /**
     * @param argument The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("sxwxhctaedewusiy")
    public suspend fun routeRules(vararg argument: suspend EdgeCacheServiceRoutingPathMatcherRouteRuleArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            EdgeCacheServiceRoutingPathMatcherRouteRuleArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.routeRules = mapped
    }

    /**
     * @param argument The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("qupcxbirkhqjgvra")
    public suspend fun routeRules(argument: suspend EdgeCacheServiceRoutingPathMatcherRouteRuleArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            EdgeCacheServiceRoutingPathMatcherRouteRuleArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.routeRules = mapped
    }

    /**
     * @param values The routeRules to match against. routeRules support advanced routing behaviour, and can match on paths, headers and query parameters, as well as status codes and HTTP methods.
     * Structure is documented below.
     */
    @JvmName("qhpactebuwfhnplt")
    public suspend fun routeRules(vararg values: EdgeCacheServiceRoutingPathMatcherRouteRuleArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.routeRules = mapped
    }

    internal fun build(): EdgeCacheServiceRoutingPathMatcherArgs =
        EdgeCacheServiceRoutingPathMatcherArgs(
            description = description,
            name = name ?: throw PulumiNullFieldException("name"),
            routeRules = routeRules ?: throw PulumiNullFieldException("routeRules"),
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy