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

com.pulumi.gcp.compute.kotlin.inputs.ReservationSpecificReservationInstancePropertiesArgs.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.compute.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.compute.inputs.ReservationSpecificReservationInstancePropertiesArgs.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 guestAccelerators Guest accelerator type and count.
 * Structure is documented below.
 * @property localSsds The amount of local ssd to reserve with each instance. This
 * reserves disks of type `local-ssd`.
 * Structure is documented below.
 * @property machineType The name of the machine type to reserve.
 * @property minCpuPlatform The minimum CPU platform for the reservation. For example,
 * `"Intel Skylake"`. See
 * the CPU platform availability reference](https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform#availablezones)
 * for information on available CPU platforms.
 */
public data class ReservationSpecificReservationInstancePropertiesArgs(
    public val guestAccelerators: Output>? = null,
    public val localSsds: Output>? =
        null,
    public val machineType: Output,
    public val minCpuPlatform: Output? = null,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.compute.inputs.ReservationSpecificReservationInstancePropertiesArgs =
        com.pulumi.gcp.compute.inputs.ReservationSpecificReservationInstancePropertiesArgs.builder()
            .guestAccelerators(
                guestAccelerators?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .localSsds(
                localSsds?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .machineType(machineType.applyValue({ args0 -> args0 }))
            .minCpuPlatform(minCpuPlatform?.applyValue({ args0 -> args0 })).build()
}

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

    private var localSsds: Output>? =
        null

    private var machineType: Output? = null

    private var minCpuPlatform: Output? = null

    /**
     * @param value Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("ibnkqgmwbvmemrff")
    public suspend fun guestAccelerators(`value`: Output>) {
        this.guestAccelerators = value
    }

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

    /**
     * @param values Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("tljusobeiqwvmtfb")
    public suspend fun guestAccelerators(values: List>) {
        this.guestAccelerators = Output.all(values)
    }

    /**
     * @param value The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("kslcuqkcctnqimfd")
    public suspend fun localSsds(`value`: Output>) {
        this.localSsds = value
    }

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

    /**
     * @param values The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("rjodkfxhypgvmuvq")
    public suspend fun localSsds(values: List>) {
        this.localSsds = Output.all(values)
    }

    /**
     * @param value The name of the machine type to reserve.
     */
    @JvmName("joyryjpuilouiiqv")
    public suspend fun machineType(`value`: Output) {
        this.machineType = value
    }

    /**
     * @param value The minimum CPU platform for the reservation. For example,
     * `"Intel Skylake"`. See
     * the CPU platform availability reference](https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform#availablezones)
     * for information on available CPU platforms.
     */
    @JvmName("niqorprqwkdaptrn")
    public suspend fun minCpuPlatform(`value`: Output) {
        this.minCpuPlatform = value
    }

    /**
     * @param value Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("krakuitqetbsrtec")
    public suspend fun guestAccelerators(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.guestAccelerators = mapped
    }

    /**
     * @param argument Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("uewsshacyulfcrkp")
    public suspend fun guestAccelerators(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param argument Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("pohajktfusysxtch")
    public suspend fun guestAccelerators(vararg argument: suspend ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param argument Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("bfssqgklikdvfqnv")
    public suspend fun guestAccelerators(argument: suspend ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgsBuilder().applySuspend
                    { argument() }.build(),
            )
        val mapped = of(toBeMapped)
        this.guestAccelerators = mapped
    }

    /**
     * @param values Guest accelerator type and count.
     * Structure is documented below.
     */
    @JvmName("vayykkvmxlkjknxr")
    public suspend fun guestAccelerators(vararg values: ReservationSpecificReservationInstancePropertiesGuestAcceleratorArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.guestAccelerators = mapped
    }

    /**
     * @param value The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("ebsstnvsajdcacdh")
    public suspend fun localSsds(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.localSsds = mapped
    }

    /**
     * @param argument The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("ndumliljbuqsoslg")
    public suspend fun localSsds(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ReservationSpecificReservationInstancePropertiesLocalSsdArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.localSsds = mapped
    }

    /**
     * @param argument The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("uoctiyvxxbdieuof")
    public suspend fun localSsds(vararg argument: suspend ReservationSpecificReservationInstancePropertiesLocalSsdArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ReservationSpecificReservationInstancePropertiesLocalSsdArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.localSsds = mapped
    }

    /**
     * @param argument The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("ihlgkkwimfeveobc")
    public suspend fun localSsds(argument: suspend ReservationSpecificReservationInstancePropertiesLocalSsdArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                ReservationSpecificReservationInstancePropertiesLocalSsdArgsBuilder().applySuspend {
                    argument()
                }.build(),
            )
        val mapped = of(toBeMapped)
        this.localSsds = mapped
    }

    /**
     * @param values The amount of local ssd to reserve with each instance. This
     * reserves disks of type `local-ssd`.
     * Structure is documented below.
     */
    @JvmName("ipnmxbbengnxllnv")
    public suspend fun localSsds(vararg values: ReservationSpecificReservationInstancePropertiesLocalSsdArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.localSsds = mapped
    }

    /**
     * @param value The name of the machine type to reserve.
     */
    @JvmName("aslepdnlarwdlhwy")
    public suspend fun machineType(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.machineType = mapped
    }

    /**
     * @param value The minimum CPU platform for the reservation. For example,
     * `"Intel Skylake"`. See
     * the CPU platform availability reference](https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform#availablezones)
     * for information on available CPU platforms.
     */
    @JvmName("ujfcoaciamvsypmh")
    public suspend fun minCpuPlatform(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.minCpuPlatform = mapped
    }

    internal fun build(): ReservationSpecificReservationInstancePropertiesArgs =
        ReservationSpecificReservationInstancePropertiesArgs(
            guestAccelerators = guestAccelerators,
            localSsds = localSsds,
            machineType = machineType ?: throw PulumiNullFieldException("machineType"),
            minCpuPlatform = minCpuPlatform,
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy