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

com.pulumi.kubernetes.resource.v1alpha3.kotlin.inputs.DeviceClaimPatchArgs.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: 4.18.2.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.kubernetes.resource.v1alpha3.kotlin.inputs

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 com.pulumi.kubernetes.resource.v1alpha3.inputs.DeviceClaimPatchArgs.builder
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * DeviceClaim defines how to request devices with a ResourceClaim.
 * @property config This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
 * @property constraints These constraints must be satisfied by the set of devices that get allocated for the claim.
 * @property requests Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
 */
public data class DeviceClaimPatchArgs(
    public val config: Output>? = null,
    public val constraints: Output>? = null,
    public val requests: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.kubernetes.resource.v1alpha3.inputs.DeviceClaimPatchArgs =
        com.pulumi.kubernetes.resource.v1alpha3.inputs.DeviceClaimPatchArgs.builder()
            .config(config?.applyValue({ args0 -> args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) }) }))
            .constraints(
                constraints?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .requests(
                requests?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

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

    private var constraints: Output>? = null

    private var requests: Output>? = null

    /**
     * @param value This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("jwterwlagvijnoir")
    public suspend fun config(`value`: Output>) {
        this.config = value
    }

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

    /**
     * @param values This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("nyxsesmbumgmmpsy")
    public suspend fun config(values: List>) {
        this.config = Output.all(values)
    }

    /**
     * @param value These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("fpjqmqucqicrnqra")
    public suspend fun constraints(`value`: Output>) {
        this.constraints = value
    }

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

    /**
     * @param values These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("gcpfvmxpibnqslkj")
    public suspend fun constraints(values: List>) {
        this.constraints = Output.all(values)
    }

    /**
     * @param value Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("lsmtibsjtbpltclb")
    public suspend fun requests(`value`: Output>) {
        this.requests = value
    }

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

    /**
     * @param values Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("fubfirrfnsppceym")
    public suspend fun requests(values: List>) {
        this.requests = Output.all(values)
    }

    /**
     * @param value This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("idrkicqiuysqdcfp")
    public suspend fun config(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.config = mapped
    }

    /**
     * @param argument This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("eqpgdettahwqxyro")
    public suspend fun config(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            DeviceClaimConfigurationPatchArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.config = mapped
    }

    /**
     * @param argument This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("hbyuoluunimytatj")
    public suspend fun config(vararg argument: suspend DeviceClaimConfigurationPatchArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            DeviceClaimConfigurationPatchArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.config = mapped
    }

    /**
     * @param argument This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("ypvkeubuahufmptw")
    public suspend fun config(argument: suspend DeviceClaimConfigurationPatchArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            DeviceClaimConfigurationPatchArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.config = mapped
    }

    /**
     * @param values This field holds configuration for multiple potential drivers which could satisfy requests in this claim. It is ignored while allocating the claim.
     */
    @JvmName("hsnqjrovwdyckcwf")
    public suspend fun config(vararg values: DeviceClaimConfigurationPatchArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.config = mapped
    }

    /**
     * @param value These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("nlobnmbegdjjgxwa")
    public suspend fun constraints(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.constraints = mapped
    }

    /**
     * @param argument These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("awrhaqawrfhkxmby")
    public suspend fun constraints(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            DeviceConstraintPatchArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.constraints = mapped
    }

    /**
     * @param argument These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("kieeuitlcudsfuoj")
    public suspend fun constraints(vararg argument: suspend DeviceConstraintPatchArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            DeviceConstraintPatchArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.constraints = mapped
    }

    /**
     * @param argument These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("asuikgempljnaigi")
    public suspend fun constraints(argument: suspend DeviceConstraintPatchArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(DeviceConstraintPatchArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.constraints = mapped
    }

    /**
     * @param values These constraints must be satisfied by the set of devices that get allocated for the claim.
     */
    @JvmName("tpmlxvykpxmvloxf")
    public suspend fun constraints(vararg values: DeviceConstraintPatchArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.constraints = mapped
    }

    /**
     * @param value Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("bjdvmbcuffccrwut")
    public suspend fun requests(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.requests = mapped
    }

    /**
     * @param argument Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("jburoyuybmmfatrt")
    public suspend fun requests(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            DeviceRequestPatchArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.requests = mapped
    }

    /**
     * @param argument Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("nwkyajfcdcicjlsd")
    public suspend fun requests(vararg argument: suspend DeviceRequestPatchArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            DeviceRequestPatchArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.requests = mapped
    }

    /**
     * @param argument Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("xgqbcodvidbtrpml")
    public suspend fun requests(argument: suspend DeviceRequestPatchArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(DeviceRequestPatchArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.requests = mapped
    }

    /**
     * @param values Requests represent individual requests for distinct devices which must all be satisfied. If empty, nothing needs to be allocated.
     */
    @JvmName("ffnmamwtxjclrcba")
    public suspend fun requests(vararg values: DeviceRequestPatchArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.requests = mapped
    }

    internal fun build(): DeviceClaimPatchArgs = DeviceClaimPatchArgs(
        config = config,
        constraints = constraints,
        requests = requests,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy