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

com.pulumi.awsnative.cassandra.kotlin.CassandraFunctions.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.cassandra.kotlin

import com.pulumi.awsnative.cassandra.CassandraFunctions.getKeyspacePlain
import com.pulumi.awsnative.cassandra.CassandraFunctions.getTablePlain
import com.pulumi.awsnative.cassandra.kotlin.inputs.GetKeyspacePlainArgs
import com.pulumi.awsnative.cassandra.kotlin.inputs.GetKeyspacePlainArgsBuilder
import com.pulumi.awsnative.cassandra.kotlin.inputs.GetTablePlainArgs
import com.pulumi.awsnative.cassandra.kotlin.inputs.GetTablePlainArgsBuilder
import com.pulumi.awsnative.cassandra.kotlin.outputs.GetKeyspaceResult
import com.pulumi.awsnative.cassandra.kotlin.outputs.GetTableResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.awsnative.cassandra.kotlin.outputs.GetKeyspaceResult.Companion.toKotlin as getKeyspaceResultToKotlin
import com.pulumi.awsnative.cassandra.kotlin.outputs.GetTableResult.Companion.toKotlin as getTableResultToKotlin

public object CassandraFunctions {
    /**
     * Resource schema for AWS::Cassandra::Keyspace
     * @param argument null
     * @return null
     */
    public suspend fun getKeyspace(argument: GetKeyspacePlainArgs): GetKeyspaceResult =
        getKeyspaceResultToKotlin(getKeyspacePlain(argument.toJava()).await())

    /**
     * @see [getKeyspace].
     * @param keyspaceName Name for Cassandra keyspace
     * @return null
     */
    public suspend fun getKeyspace(keyspaceName: String): GetKeyspaceResult {
        val argument = GetKeyspacePlainArgs(
            keyspaceName = keyspaceName,
        )
        return getKeyspaceResultToKotlin(getKeyspacePlain(argument.toJava()).await())
    }

    /**
     * @see [getKeyspace].
     * @param argument Builder for [com.pulumi.awsnative.cassandra.kotlin.inputs.GetKeyspacePlainArgs].
     * @return null
     */
    public suspend fun getKeyspace(argument: suspend GetKeyspacePlainArgsBuilder.() -> Unit): GetKeyspaceResult {
        val builder = GetKeyspacePlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getKeyspaceResultToKotlin(getKeyspacePlain(builtArgument.toJava()).await())
    }

    /**
     * Resource schema for AWS::Cassandra::Table
     * @param argument null
     * @return null
     */
    public suspend fun getTable(argument: GetTablePlainArgs): GetTableResult =
        getTableResultToKotlin(getTablePlain(argument.toJava()).await())

    /**
     * @see [getTable].
     * @param keyspaceName Name for Cassandra keyspace
     * @param tableName Name for Cassandra table
     * @return null
     */
    public suspend fun getTable(keyspaceName: String, tableName: String): GetTableResult {
        val argument = GetTablePlainArgs(
            keyspaceName = keyspaceName,
            tableName = tableName,
        )
        return getTableResultToKotlin(getTablePlain(argument.toJava()).await())
    }

    /**
     * @see [getTable].
     * @param argument Builder for [com.pulumi.awsnative.cassandra.kotlin.inputs.GetTablePlainArgs].
     * @return null
     */
    public suspend fun getTable(argument: suspend GetTablePlainArgsBuilder.() -> Unit): GetTableResult {
        val builder = GetTablePlainArgsBuilder()
        builder.argument()
        val builtArgument = builder.build()
        return getTableResultToKotlin(getTablePlain(builtArgument.toJava()).await())
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy