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

com.pulumi.azurenative.network.kotlin.inputs.BackendPoolArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.network.kotlin.inputs

import com.pulumi.azurenative.network.inputs.BackendPoolArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
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

/**
 * A backend pool is a collection of backends that can be routed to.
 * @property backends The set of backends for this pool
 * @property healthProbeSettings L7 health probe settings for a backend pool
 * @property id Resource ID.
 * @property loadBalancingSettings Load balancing settings for a backend pool
 * @property name Resource name.
 */
public data class BackendPoolArgs(
    public val backends: Output>? = null,
    public val healthProbeSettings: Output? = null,
    public val id: Output? = null,
    public val loadBalancingSettings: Output? = null,
    public val name: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.network.inputs.BackendPoolArgs =
        com.pulumi.azurenative.network.inputs.BackendPoolArgs.builder()
            .backends(
                backends?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .healthProbeSettings(
                healthProbeSettings?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .id(id?.applyValue({ args0 -> args0 }))
            .loadBalancingSettings(
                loadBalancingSettings?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .name(name?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [BackendPoolArgs].
 */
@PulumiTagMarker
public class BackendPoolArgsBuilder internal constructor() {
    private var backends: Output>? = null

    private var healthProbeSettings: Output? = null

    private var id: Output? = null

    private var loadBalancingSettings: Output? = null

    private var name: Output? = null

    /**
     * @param value The set of backends for this pool
     */
    @JvmName("jwclfoscangrypip")
    public suspend fun backends(`value`: Output>) {
        this.backends = value
    }

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

    /**
     * @param values The set of backends for this pool
     */
    @JvmName("kejvuxttixflhtku")
    public suspend fun backends(values: List>) {
        this.backends = Output.all(values)
    }

    /**
     * @param value L7 health probe settings for a backend pool
     */
    @JvmName("rwprxembgkyqistp")
    public suspend fun healthProbeSettings(`value`: Output) {
        this.healthProbeSettings = value
    }

    /**
     * @param value Resource ID.
     */
    @JvmName("djfqouvuiekxmxgn")
    public suspend fun id(`value`: Output) {
        this.id = value
    }

    /**
     * @param value Load balancing settings for a backend pool
     */
    @JvmName("txigdgicgnwaqlvf")
    public suspend fun loadBalancingSettings(`value`: Output) {
        this.loadBalancingSettings = value
    }

    /**
     * @param value Resource name.
     */
    @JvmName("fskbukrigqcwlmjs")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The set of backends for this pool
     */
    @JvmName("voyvujkhujcgtxlq")
    public suspend fun backends(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.backends = mapped
    }

    /**
     * @param argument The set of backends for this pool
     */
    @JvmName("kotlmqupsygpofud")
    public suspend fun backends(argument: List Unit>) {
        val toBeMapped = argument.toList().map { BackendArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.backends = mapped
    }

    /**
     * @param argument The set of backends for this pool
     */
    @JvmName("ugcineodacmousfu")
    public suspend fun backends(vararg argument: suspend BackendArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map { BackendArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.backends = mapped
    }

    /**
     * @param argument The set of backends for this pool
     */
    @JvmName("jjrampdomxwlsfij")
    public suspend fun backends(argument: suspend BackendArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(BackendArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.backends = mapped
    }

    /**
     * @param values The set of backends for this pool
     */
    @JvmName("oavuyfedritumlfa")
    public suspend fun backends(vararg values: BackendArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.backends = mapped
    }

    /**
     * @param value L7 health probe settings for a backend pool
     */
    @JvmName("wqwirbhujrlryyub")
    public suspend fun healthProbeSettings(`value`: SubResourceArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.healthProbeSettings = mapped
    }

    /**
     * @param argument L7 health probe settings for a backend pool
     */
    @JvmName("knlnifnubdcofuxx")
    public suspend fun healthProbeSettings(argument: suspend SubResourceArgsBuilder.() -> Unit) {
        val toBeMapped = SubResourceArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.healthProbeSettings = mapped
    }

    /**
     * @param value Resource ID.
     */
    @JvmName("lhflknkqpxkonhjh")
    public suspend fun id(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.id = mapped
    }

    /**
     * @param value Load balancing settings for a backend pool
     */
    @JvmName("tedqdkqjrrxdgbju")
    public suspend fun loadBalancingSettings(`value`: SubResourceArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.loadBalancingSettings = mapped
    }

    /**
     * @param argument Load balancing settings for a backend pool
     */
    @JvmName("oldvtcekffyjsnuy")
    public suspend fun loadBalancingSettings(argument: suspend SubResourceArgsBuilder.() -> Unit) {
        val toBeMapped = SubResourceArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.loadBalancingSettings = mapped
    }

    /**
     * @param value Resource name.
     */
    @JvmName("yvjompikxrreeojt")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    internal fun build(): BackendPoolArgs = BackendPoolArgs(
        backends = backends,
        healthProbeSettings = healthProbeSettings,
        id = id,
        loadBalancingSettings = loadBalancingSettings,
        name = name,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy