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

com.pulumi.gcp.appengine.kotlin.inputs.FlexibleAppVersionResourcesArgs.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.20.1.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.appengine.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.appengine.inputs.FlexibleAppVersionResourcesArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Double
import kotlin.Int
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property cpu Number of CPU cores needed.
 * @property diskGb Disk size (GB) needed.
 * @property memoryGb Memory (GB) needed.
 * @property volumes List of ports, or port pairs, to forward from the virtual machine to the application container.
 * Structure is documented below.
 */
public data class FlexibleAppVersionResourcesArgs(
    public val cpu: Output? = null,
    public val diskGb: Output? = null,
    public val memoryGb: Output? = null,
    public val volumes: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.appengine.inputs.FlexibleAppVersionResourcesArgs =
        com.pulumi.gcp.appengine.inputs.FlexibleAppVersionResourcesArgs.builder()
            .cpu(cpu?.applyValue({ args0 -> args0 }))
            .diskGb(diskGb?.applyValue({ args0 -> args0 }))
            .memoryGb(memoryGb?.applyValue({ args0 -> args0 }))
            .volumes(
                volumes?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [FlexibleAppVersionResourcesArgs].
 */
@PulumiTagMarker
public class FlexibleAppVersionResourcesArgsBuilder internal constructor() {
    private var cpu: Output? = null

    private var diskGb: Output? = null

    private var memoryGb: Output? = null

    private var volumes: Output>? = null

    /**
     * @param value Number of CPU cores needed.
     */
    @JvmName("ptgxutrkywsyqviq")
    public suspend fun cpu(`value`: Output) {
        this.cpu = value
    }

    /**
     * @param value Disk size (GB) needed.
     */
    @JvmName("vetudncklasqtoln")
    public suspend fun diskGb(`value`: Output) {
        this.diskGb = value
    }

    /**
     * @param value Memory (GB) needed.
     */
    @JvmName("pdffsaakrledmvmo")
    public suspend fun memoryGb(`value`: Output) {
        this.memoryGb = value
    }

    /**
     * @param value List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("onqbdniwtyhituga")
    public suspend fun volumes(`value`: Output>) {
        this.volumes = value
    }

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

    /**
     * @param values List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("kxsqxkrrixyfdjou")
    public suspend fun volumes(values: List>) {
        this.volumes = Output.all(values)
    }

    /**
     * @param value Number of CPU cores needed.
     */
    @JvmName("sqanbpfbqrjraiqi")
    public suspend fun cpu(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cpu = mapped
    }

    /**
     * @param value Disk size (GB) needed.
     */
    @JvmName("xpihiurcalcgfnrc")
    public suspend fun diskGb(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.diskGb = mapped
    }

    /**
     * @param value Memory (GB) needed.
     */
    @JvmName("gdcaihqqyjswejlu")
    public suspend fun memoryGb(`value`: Double?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.memoryGb = mapped
    }

    /**
     * @param value List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("sroijwpjidrywtnl")
    public suspend fun volumes(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.volumes = mapped
    }

    /**
     * @param argument List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("pgahbqapmmfkotac")
    public suspend fun volumes(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            FlexibleAppVersionResourcesVolumeArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param argument List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("lyigfrkhgapnprjf")
    public suspend fun volumes(vararg argument: suspend FlexibleAppVersionResourcesVolumeArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            FlexibleAppVersionResourcesVolumeArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param argument List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("ulfimudgrwvkcyye")
    public suspend fun volumes(argument: suspend FlexibleAppVersionResourcesVolumeArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            FlexibleAppVersionResourcesVolumeArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.volumes = mapped
    }

    /**
     * @param values List of ports, or port pairs, to forward from the virtual machine to the application container.
     * Structure is documented below.
     */
    @JvmName("egvganyjxytwyvmj")
    public suspend fun volumes(vararg values: FlexibleAppVersionResourcesVolumeArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.volumes = mapped
    }

    internal fun build(): FlexibleAppVersionResourcesArgs = FlexibleAppVersionResourcesArgs(
        cpu = cpu,
        diskGb = diskGb,
        memoryGb = memoryGb,
        volumes = volumes,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy