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

com.pulumi.awsnative.batch.kotlin.inputs.JobDefinitionNodePropertiesArgs.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.batch.kotlin.inputs

import com.pulumi.awsnative.batch.inputs.JobDefinitionNodePropertiesArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Int
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property mainNode Specifies the node index for the main node of a multi-node parallel job. This node index value must be fewer than the number of nodes.
 * @property nodeRangeProperties A list of node ranges and their properties that are associated with a multi-node parallel job.
 * @property numNodes The number of nodes that are associated with a multi-node parallel job.
 */
public data class JobDefinitionNodePropertiesArgs(
    public val mainNode: Output,
    public val nodeRangeProperties: Output>,
    public val numNodes: Output,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.batch.inputs.JobDefinitionNodePropertiesArgs =
        com.pulumi.awsnative.batch.inputs.JobDefinitionNodePropertiesArgs.builder()
            .mainNode(mainNode.applyValue({ args0 -> args0 }))
            .nodeRangeProperties(
                nodeRangeProperties.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .numNodes(numNodes.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [JobDefinitionNodePropertiesArgs].
 */
@PulumiTagMarker
public class JobDefinitionNodePropertiesArgsBuilder internal constructor() {
    private var mainNode: Output? = null

    private var nodeRangeProperties: Output>? = null

    private var numNodes: Output? = null

    /**
     * @param value Specifies the node index for the main node of a multi-node parallel job. This node index value must be fewer than the number of nodes.
     */
    @JvmName("hqdffukamkjlvnmj")
    public suspend fun mainNode(`value`: Output) {
        this.mainNode = value
    }

    /**
     * @param value A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("obulkqwrfgstaiqw")
    public suspend fun nodeRangeProperties(`value`: Output>) {
        this.nodeRangeProperties = value
    }

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

    /**
     * @param values A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("wrhjkbnafbvabswl")
    public suspend fun nodeRangeProperties(values: List>) {
        this.nodeRangeProperties = Output.all(values)
    }

    /**
     * @param value The number of nodes that are associated with a multi-node parallel job.
     */
    @JvmName("hyrlxefuilexmmly")
    public suspend fun numNodes(`value`: Output) {
        this.numNodes = value
    }

    /**
     * @param value Specifies the node index for the main node of a multi-node parallel job. This node index value must be fewer than the number of nodes.
     */
    @JvmName("wkwhpwdumbmthwvm")
    public suspend fun mainNode(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.mainNode = mapped
    }

    /**
     * @param value A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("cnwqmwphgoorpoaj")
    public suspend fun nodeRangeProperties(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.nodeRangeProperties = mapped
    }

    /**
     * @param argument A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("awhchbdhuhuilmqc")
    public suspend fun nodeRangeProperties(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            JobDefinitionNodeRangePropertyArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.nodeRangeProperties = mapped
    }

    /**
     * @param argument A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("gtvofvwmfqlxrkcg")
    public suspend fun nodeRangeProperties(vararg argument: suspend JobDefinitionNodeRangePropertyArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            JobDefinitionNodeRangePropertyArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.nodeRangeProperties = mapped
    }

    /**
     * @param argument A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("hwvrmdqdqcalxwff")
    public suspend fun nodeRangeProperties(argument: suspend JobDefinitionNodeRangePropertyArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            JobDefinitionNodeRangePropertyArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.nodeRangeProperties = mapped
    }

    /**
     * @param values A list of node ranges and their properties that are associated with a multi-node parallel job.
     */
    @JvmName("bpxaiuaiiypqpvim")
    public suspend fun nodeRangeProperties(vararg values: JobDefinitionNodeRangePropertyArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.nodeRangeProperties = mapped
    }

    /**
     * @param value The number of nodes that are associated with a multi-node parallel job.
     */
    @JvmName("tcfhwigiloxdceph")
    public suspend fun numNodes(`value`: Int) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.numNodes = mapped
    }

    internal fun build(): JobDefinitionNodePropertiesArgs = JobDefinitionNodePropertiesArgs(
        mainNode = mainNode ?: throw PulumiNullFieldException("mainNode"),
        nodeRangeProperties = nodeRangeProperties ?: throw PulumiNullFieldException("nodeRangeProperties"),
        numNodes = numNodes ?: throw PulumiNullFieldException("numNodes"),
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy