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

com.pulumi.kubernetes.resource.v1alpha1.kotlin.outputs.ResourceClaimSpec.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.v1alpha1.kotlin.outputs

import kotlin.String
import kotlin.Suppress

/**
 * ResourceClaimSpec defines how a resource is to be allocated.
 * @property allocationMode Allocation can start immediately or when a Pod wants to use the resource. "WaitForFirstConsumer" is the default.
 * @property parametersRef ParametersRef references a separate object with arbitrary parameters that will be used by the driver when allocating a resource for the claim.
 * The object must be in the same namespace as the ResourceClaim.
 * @property resourceClassName ResourceClassName references the driver and additional parameters via the name of a ResourceClass that was created as part of the driver deployment.
 */
public data class ResourceClaimSpec(
    public val allocationMode: String? = null,
    public val parametersRef: ResourceClaimParametersReference? = null,
    public val resourceClassName: String,
) {
    public companion object {
        public fun toKotlin(javaType: com.pulumi.kubernetes.resource.v1alpha1.outputs.ResourceClaimSpec): ResourceClaimSpec = ResourceClaimSpec(
            allocationMode = javaType.allocationMode().map({ args0 -> args0 }).orElse(null),
            parametersRef = javaType.parametersRef().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.resource.v1alpha1.kotlin.outputs.ResourceClaimParametersReference.Companion.toKotlin(args0)
                })
            }).orElse(null),
            resourceClassName = javaType.resourceClassName(),
        )
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy