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

com.pulumi.awsnative.lightsail.kotlin.DiskArgs.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: 1.11.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.lightsail.kotlin

import com.pulumi.awsnative.kotlin.inputs.TagArgs
import com.pulumi.awsnative.kotlin.inputs.TagArgsBuilder
import com.pulumi.awsnative.lightsail.DiskArgs.builder
import com.pulumi.awsnative.lightsail.kotlin.inputs.DiskAddOnArgs
import com.pulumi.awsnative.lightsail.kotlin.inputs.DiskAddOnArgsBuilder
import com.pulumi.awsnative.lightsail.kotlin.inputs.DiskLocationArgs
import com.pulumi.awsnative.lightsail.kotlin.inputs.DiskLocationArgsBuilder
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.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Resource Type definition for AWS::Lightsail::Disk
 * @property addOns An array of objects representing the add-ons to enable for the new instance.
 * @property availabilityZone The Availability Zone in which to create your instance. Use the following format: us-east-2a (case sensitive). Be sure to add the include Availability Zones parameter to your request.
 * @property diskName The names to use for your new Lightsail disk.
 * @property location The AWS Region and Availability Zone where the disk is located.
 * @property sizeInGb Size of the Lightsail disk
 * @property tags An array of key-value pairs to apply to this resource.
 */
public data class DiskArgs(
    public val addOns: Output>? = null,
    public val availabilityZone: Output? = null,
    public val diskName: Output? = null,
    public val location: Output? = null,
    public val sizeInGb: Output? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.lightsail.DiskArgs =
        com.pulumi.awsnative.lightsail.DiskArgs.builder()
            .addOns(addOns?.applyValue({ args0 -> args0.map({ args0 -> args0.let({ args0 -> args0.toJava() }) }) }))
            .availabilityZone(availabilityZone?.applyValue({ args0 -> args0 }))
            .diskName(diskName?.applyValue({ args0 -> args0 }))
            .location(location?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .sizeInGb(sizeInGb?.applyValue({ args0 -> args0 }))
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

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

    private var availabilityZone: Output? = null

    private var diskName: Output? = null

    private var location: Output? = null

    private var sizeInGb: Output? = null

    private var tags: Output>? = null

    /**
     * @param value An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("glwxonnaqlpueueq")
    public suspend fun addOns(`value`: Output>) {
        this.addOns = value
    }

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

    /**
     * @param values An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("hvnehiooyyrictgc")
    public suspend fun addOns(values: List>) {
        this.addOns = Output.all(values)
    }

    /**
     * @param value The Availability Zone in which to create your instance. Use the following format: us-east-2a (case sensitive). Be sure to add the include Availability Zones parameter to your request.
     */
    @JvmName("dtwhochddkskasit")
    public suspend fun availabilityZone(`value`: Output) {
        this.availabilityZone = value
    }

    /**
     * @param value The names to use for your new Lightsail disk.
     */
    @JvmName("qqqtbxjmwhnioyuu")
    public suspend fun diskName(`value`: Output) {
        this.diskName = value
    }

    /**
     * @param value The AWS Region and Availability Zone where the disk is located.
     */
    @JvmName("xnvmgbysqwffhidt")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value Size of the Lightsail disk
     */
    @JvmName("yuxokjfdfxoedapo")
    public suspend fun sizeInGb(`value`: Output) {
        this.sizeInGb = value
    }

    /**
     * @param value An array of key-value pairs to apply to this resource.
     */
    @JvmName("bpwepuyjehabulfd")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

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

    /**
     * @param values An array of key-value pairs to apply to this resource.
     */
    @JvmName("djcwktparjobudqd")
    public suspend fun tags(values: List>) {
        this.tags = Output.all(values)
    }

    /**
     * @param value An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("nheinpuihlojhkjm")
    public suspend fun addOns(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.addOns = mapped
    }

    /**
     * @param argument An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("dfernmjdkqlwayys")
    public suspend fun addOns(argument: List Unit>) {
        val toBeMapped = argument.toList().map { DiskAddOnArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.addOns = mapped
    }

    /**
     * @param argument An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("xglxpnponodsjjjl")
    public suspend fun addOns(vararg argument: suspend DiskAddOnArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map { DiskAddOnArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.addOns = mapped
    }

    /**
     * @param argument An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("encxbsrawakhsspf")
    public suspend fun addOns(argument: suspend DiskAddOnArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(DiskAddOnArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.addOns = mapped
    }

    /**
     * @param values An array of objects representing the add-ons to enable for the new instance.
     */
    @JvmName("jbsisrmablthbvew")
    public suspend fun addOns(vararg values: DiskAddOnArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.addOns = mapped
    }

    /**
     * @param value The Availability Zone in which to create your instance. Use the following format: us-east-2a (case sensitive). Be sure to add the include Availability Zones parameter to your request.
     */
    @JvmName("aapmctxetlmtrbxx")
    public suspend fun availabilityZone(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.availabilityZone = mapped
    }

    /**
     * @param value The names to use for your new Lightsail disk.
     */
    @JvmName("otmvkcjguilyndrc")
    public suspend fun diskName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.diskName = mapped
    }

    /**
     * @param value The AWS Region and Availability Zone where the disk is located.
     */
    @JvmName("pfxjfjsvfboelluy")
    public suspend fun location(`value`: DiskLocationArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param argument The AWS Region and Availability Zone where the disk is located.
     */
    @JvmName("jmpvxdydrywmwxat")
    public suspend fun location(argument: suspend DiskLocationArgsBuilder.() -> Unit) {
        val toBeMapped = DiskLocationArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.location = mapped
    }

    /**
     * @param value Size of the Lightsail disk
     */
    @JvmName("odfbufwgieyribsl")
    public suspend fun sizeInGb(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sizeInGb = mapped
    }

    /**
     * @param value An array of key-value pairs to apply to this resource.
     */
    @JvmName("lttxkyvrfnsegato")
    public suspend fun tags(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("pooslqcyjaqoleod")
    public suspend fun tags(argument: List Unit>) {
        val toBeMapped = argument.toList().map { TagArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("njarnlkmupjatihg")
    public suspend fun tags(vararg argument: suspend TagArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map { TagArgsBuilder().applySuspend { it() }.build() }
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param argument An array of key-value pairs to apply to this resource.
     */
    @JvmName("nbklifktfncppgun")
    public suspend fun tags(argument: suspend TagArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(TagArgsBuilder().applySuspend { argument() }.build())
        val mapped = of(toBeMapped)
        this.tags = mapped
    }

    /**
     * @param values An array of key-value pairs to apply to this resource.
     */
    @JvmName("hyvelafcegsdpvfr")
    public suspend fun tags(vararg values: TagArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): DiskArgs = DiskArgs(
        addOns = addOns,
        availabilityZone = availabilityZone,
        diskName = diskName,
        location = location,
        sizeInGb = sizeInGb,
        tags = tags,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy