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

com.pulumi.awsnative.batch.kotlin.BatchFunctions.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.batch.kotlin

import com.pulumi.awsnative.batch.BatchFunctions.getComputeEnvironmentPlain
import com.pulumi.awsnative.batch.BatchFunctions.getJobDefinitionPlain
import com.pulumi.awsnative.batch.BatchFunctions.getJobQueuePlain
import com.pulumi.awsnative.batch.BatchFunctions.getSchedulingPolicyPlain
import com.pulumi.awsnative.batch.kotlin.inputs.GetComputeEnvironmentPlainArgs
import com.pulumi.awsnative.batch.kotlin.inputs.GetComputeEnvironmentPlainArgsBuilder
import com.pulumi.awsnative.batch.kotlin.inputs.GetJobDefinitionPlainArgs
import com.pulumi.awsnative.batch.kotlin.inputs.GetJobDefinitionPlainArgsBuilder
import com.pulumi.awsnative.batch.kotlin.inputs.GetJobQueuePlainArgs
import com.pulumi.awsnative.batch.kotlin.inputs.GetJobQueuePlainArgsBuilder
import com.pulumi.awsnative.batch.kotlin.inputs.GetSchedulingPolicyPlainArgs
import com.pulumi.awsnative.batch.kotlin.inputs.GetSchedulingPolicyPlainArgsBuilder
import com.pulumi.awsnative.batch.kotlin.outputs.GetComputeEnvironmentResult
import com.pulumi.awsnative.batch.kotlin.outputs.GetJobDefinitionResult
import com.pulumi.awsnative.batch.kotlin.outputs.GetJobQueueResult
import com.pulumi.awsnative.batch.kotlin.outputs.GetSchedulingPolicyResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.awsnative.batch.kotlin.outputs.GetComputeEnvironmentResult.Companion.toKotlin as getComputeEnvironmentResultToKotlin
import com.pulumi.awsnative.batch.kotlin.outputs.GetJobDefinitionResult.Companion.toKotlin as getJobDefinitionResultToKotlin
import com.pulumi.awsnative.batch.kotlin.outputs.GetJobQueueResult.Companion.toKotlin as getJobQueueResultToKotlin
import com.pulumi.awsnative.batch.kotlin.outputs.GetSchedulingPolicyResult.Companion.toKotlin as getSchedulingPolicyResultToKotlin

public object BatchFunctions {
    /**
     * Resource Type definition for AWS::Batch::ComputeEnvironment
     * @param argument null
     * @return null
     */
    public suspend fun getComputeEnvironment(argument: GetComputeEnvironmentPlainArgs): GetComputeEnvironmentResult =
        getComputeEnvironmentResultToKotlin(getComputeEnvironmentPlain(argument.toJava()).await())

    /**
     * @see [getComputeEnvironment].
     * @param computeEnvironmentArn Returns the compute environment ARN, such as `batch: *us-east-1* : *111122223333* :compute-environment/ *ComputeEnvironmentName*` .
     * @return null
     */
    public suspend fun getComputeEnvironment(computeEnvironmentArn: String): GetComputeEnvironmentResult {
        val argument = GetComputeEnvironmentPlainArgs(
            computeEnvironmentArn = computeEnvironmentArn,
        )
        return getComputeEnvironmentResultToKotlin(getComputeEnvironmentPlain(argument.toJava()).await())
    }

    /**
     * @see [getComputeEnvironment].
     * @param argument Builder for [com.pulumi.awsnative.batch.kotlin.inputs.GetComputeEnvironmentPlainArgs].
     * @return null
     */
    public suspend fun getComputeEnvironment(argument: suspend GetComputeEnvironmentPlainArgsBuilder.() -> Unit): GetComputeEnvironmentResult {
        val builder = GetComputeEnvironmentPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getComputeEnvironmentResultToKotlin(getComputeEnvironmentPlain(builtArgument.toJava()).await())
    }

    /**
     * Resource Type definition for AWS::Batch::JobDefinition
     * @param argument null
     * @return null
     */
    public suspend fun getJobDefinition(argument: GetJobDefinitionPlainArgs): GetJobDefinitionResult =
        getJobDefinitionResultToKotlin(getJobDefinitionPlain(argument.toJava()).await())

    /**
     * @see [getJobDefinition].
     * @param id
     * @return null
     */
    public suspend fun getJobDefinition(id: String): GetJobDefinitionResult {
        val argument = GetJobDefinitionPlainArgs(
            id = id,
        )
        return getJobDefinitionResultToKotlin(getJobDefinitionPlain(argument.toJava()).await())
    }

    /**
     * @see [getJobDefinition].
     * @param argument Builder for [com.pulumi.awsnative.batch.kotlin.inputs.GetJobDefinitionPlainArgs].
     * @return null
     */
    public suspend fun getJobDefinition(argument: suspend GetJobDefinitionPlainArgsBuilder.() -> Unit): GetJobDefinitionResult {
        val builder = GetJobDefinitionPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getJobDefinitionResultToKotlin(getJobDefinitionPlain(builtArgument.toJava()).await())
    }

    /**
     * Resource Type definition for AWS::Batch::JobQueue
     * @param argument null
     * @return null
     */
    public suspend fun getJobQueue(argument: GetJobQueuePlainArgs): GetJobQueueResult =
        getJobQueueResultToKotlin(getJobQueuePlain(argument.toJava()).await())

    /**
     * @see [getJobQueue].
     * @param jobQueueArn Returns the job queue ARN, such as `batch: *us-east-1* : *111122223333* :job-queue/ *JobQueueName*` .
     * @return null
     */
    public suspend fun getJobQueue(jobQueueArn: String): GetJobQueueResult {
        val argument = GetJobQueuePlainArgs(
            jobQueueArn = jobQueueArn,
        )
        return getJobQueueResultToKotlin(getJobQueuePlain(argument.toJava()).await())
    }

    /**
     * @see [getJobQueue].
     * @param argument Builder for [com.pulumi.awsnative.batch.kotlin.inputs.GetJobQueuePlainArgs].
     * @return null
     */
    public suspend fun getJobQueue(argument: suspend GetJobQueuePlainArgsBuilder.() -> Unit): GetJobQueueResult {
        val builder = GetJobQueuePlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getJobQueueResultToKotlin(getJobQueuePlain(builtArgument.toJava()).await())
    }

    /**
     * Resource Type schema for AWS::Batch::SchedulingPolicy
     * @param argument null
     * @return null
     */
    public suspend fun getSchedulingPolicy(argument: GetSchedulingPolicyPlainArgs): GetSchedulingPolicyResult =
        getSchedulingPolicyResultToKotlin(getSchedulingPolicyPlain(argument.toJava()).await())

    /**
     * @see [getSchedulingPolicy].
     * @param arn Returns the scheduling policy ARN, such as `batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority*` .
     * @return null
     */
    public suspend fun getSchedulingPolicy(arn: String): GetSchedulingPolicyResult {
        val argument = GetSchedulingPolicyPlainArgs(
            arn = arn,
        )
        return getSchedulingPolicyResultToKotlin(getSchedulingPolicyPlain(argument.toJava()).await())
    }

    /**
     * @see [getSchedulingPolicy].
     * @param argument Builder for [com.pulumi.awsnative.batch.kotlin.inputs.GetSchedulingPolicyPlainArgs].
     * @return null
     */
    public suspend fun getSchedulingPolicy(argument: suspend GetSchedulingPolicyPlainArgsBuilder.() -> Unit): GetSchedulingPolicyResult {
        val builder = GetSchedulingPolicyPlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getSchedulingPolicyResultToKotlin(getSchedulingPolicyPlain(builtArgument.toJava()).await())
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy