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

com.pulumi.awsnative.timestream.kotlin.inputs.ScheduledQueryTimestreamConfigurationArgs.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.24.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.timestream.kotlin.inputs

import com.pulumi.awsnative.timestream.inputs.ScheduledQueryTimestreamConfigurationArgs.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.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Configuration needed to write data into the Timestream database and table.
 * @property databaseName Name of Timestream database to which the query result will be written.
 * @property dimensionMappings This is to allow mapping column(s) from the query result to the dimension in the destination table.
 * @property measureNameColumn Name of the measure column. Also see `MultiMeasureMappings` and `MixedMeasureMappings` for how measure name properties on those relate to `MeasureNameColumn` .
 * @property mixedMeasureMappings Specifies how to map measures to multi-measure records.
 * @property multiMeasureMappings Multi-measure mappings.
 * @property tableName Name of Timestream table that the query result will be written to. The table should be within the same database that is provided in Timestream configuration.
 * @property timeColumn Column from query result that should be used as the time column in destination table. Column type for this should be TIMESTAMP.
 */
public data class ScheduledQueryTimestreamConfigurationArgs(
    public val databaseName: Output,
    public val dimensionMappings: Output>,
    public val measureNameColumn: Output? = null,
    public val mixedMeasureMappings: Output>? = null,
    public val multiMeasureMappings: Output? = null,
    public val tableName: Output,
    public val timeColumn: Output,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.timestream.inputs.ScheduledQueryTimestreamConfigurationArgs =
        com.pulumi.awsnative.timestream.inputs.ScheduledQueryTimestreamConfigurationArgs.builder()
            .databaseName(databaseName.applyValue({ args0 -> args0 }))
            .dimensionMappings(
                dimensionMappings.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .measureNameColumn(measureNameColumn?.applyValue({ args0 -> args0 }))
            .mixedMeasureMappings(
                mixedMeasureMappings?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .multiMeasureMappings(
                multiMeasureMappings?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .tableName(tableName.applyValue({ args0 -> args0 }))
            .timeColumn(timeColumn.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [ScheduledQueryTimestreamConfigurationArgs].
 */
@PulumiTagMarker
public class ScheduledQueryTimestreamConfigurationArgsBuilder internal constructor() {
    private var databaseName: Output? = null

    private var dimensionMappings: Output>? = null

    private var measureNameColumn: Output? = null

    private var mixedMeasureMappings: Output>? = null

    private var multiMeasureMappings: Output? = null

    private var tableName: Output? = null

    private var timeColumn: Output? = null

    /**
     * @param value Name of Timestream database to which the query result will be written.
     */
    @JvmName("evriackrhbdtxxlq")
    public suspend fun databaseName(`value`: Output) {
        this.databaseName = value
    }

    /**
     * @param value This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("qlyaumbclklristr")
    public suspend fun dimensionMappings(`value`: Output>) {
        this.dimensionMappings = value
    }

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

    /**
     * @param values This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("hnhgkjujrbarssxm")
    public suspend fun dimensionMappings(values: List>) {
        this.dimensionMappings = Output.all(values)
    }

    /**
     * @param value Name of the measure column. Also see `MultiMeasureMappings` and `MixedMeasureMappings` for how measure name properties on those relate to `MeasureNameColumn` .
     */
    @JvmName("yyblhbdfkrupifje")
    public suspend fun measureNameColumn(`value`: Output) {
        this.measureNameColumn = value
    }

    /**
     * @param value Specifies how to map measures to multi-measure records.
     */
    @JvmName("xmnenxkexujsdjno")
    public suspend fun mixedMeasureMappings(`value`: Output>) {
        this.mixedMeasureMappings = value
    }

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

    /**
     * @param values Specifies how to map measures to multi-measure records.
     */
    @JvmName("hnnqvbyhafhxdlhh")
    public suspend fun mixedMeasureMappings(values: List>) {
        this.mixedMeasureMappings = Output.all(values)
    }

    /**
     * @param value Multi-measure mappings.
     */
    @JvmName("rpcmwvrhvspdcchm")
    public suspend fun multiMeasureMappings(`value`: Output) {
        this.multiMeasureMappings = value
    }

    /**
     * @param value Name of Timestream table that the query result will be written to. The table should be within the same database that is provided in Timestream configuration.
     */
    @JvmName("adijhdpiwnrfmqln")
    public suspend fun tableName(`value`: Output) {
        this.tableName = value
    }

    /**
     * @param value Column from query result that should be used as the time column in destination table. Column type for this should be TIMESTAMP.
     */
    @JvmName("knekqaanybghrdtq")
    public suspend fun timeColumn(`value`: Output) {
        this.timeColumn = value
    }

    /**
     * @param value Name of Timestream database to which the query result will be written.
     */
    @JvmName("hmumnvxemtoqtimg")
    public suspend fun databaseName(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.databaseName = mapped
    }

    /**
     * @param value This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("pmvxgxaakjchjbaa")
    public suspend fun dimensionMappings(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.dimensionMappings = mapped
    }

    /**
     * @param argument This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("dapnnseyhogiynss")
    public suspend fun dimensionMappings(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ScheduledQueryDimensionMappingArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.dimensionMappings = mapped
    }

    /**
     * @param argument This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("chcaafwinpqrtpgl")
    public suspend fun dimensionMappings(vararg argument: suspend ScheduledQueryDimensionMappingArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ScheduledQueryDimensionMappingArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.dimensionMappings = mapped
    }

    /**
     * @param argument This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("yspgrqnaxrfgofgp")
    public suspend fun dimensionMappings(argument: suspend ScheduledQueryDimensionMappingArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ScheduledQueryDimensionMappingArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.dimensionMappings = mapped
    }

    /**
     * @param values This is to allow mapping column(s) from the query result to the dimension in the destination table.
     */
    @JvmName("qbmenjuhrmjeemdq")
    public suspend fun dimensionMappings(vararg values: ScheduledQueryDimensionMappingArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.dimensionMappings = mapped
    }

    /**
     * @param value Name of the measure column. Also see `MultiMeasureMappings` and `MixedMeasureMappings` for how measure name properties on those relate to `MeasureNameColumn` .
     */
    @JvmName("shqtwwgrqknkissk")
    public suspend fun measureNameColumn(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.measureNameColumn = mapped
    }

    /**
     * @param value Specifies how to map measures to multi-measure records.
     */
    @JvmName("jjivvqdokoxkgnid")
    public suspend fun mixedMeasureMappings(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.mixedMeasureMappings = mapped
    }

    /**
     * @param argument Specifies how to map measures to multi-measure records.
     */
    @JvmName("vypixvcckrgfoqlm")
    public suspend fun mixedMeasureMappings(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ScheduledQueryMixedMeasureMappingArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.mixedMeasureMappings = mapped
    }

    /**
     * @param argument Specifies how to map measures to multi-measure records.
     */
    @JvmName("ajxptdymqyqnmshw")
    public suspend fun mixedMeasureMappings(vararg argument: suspend ScheduledQueryMixedMeasureMappingArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ScheduledQueryMixedMeasureMappingArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.mixedMeasureMappings = mapped
    }

    /**
     * @param argument Specifies how to map measures to multi-measure records.
     */
    @JvmName("bsmfyjbubmmmxtvc")
    public suspend fun mixedMeasureMappings(argument: suspend ScheduledQueryMixedMeasureMappingArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ScheduledQueryMixedMeasureMappingArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.mixedMeasureMappings = mapped
    }

    /**
     * @param values Specifies how to map measures to multi-measure records.
     */
    @JvmName("jodhndrosaarqaau")
    public suspend fun mixedMeasureMappings(vararg values: ScheduledQueryMixedMeasureMappingArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.mixedMeasureMappings = mapped
    }

    /**
     * @param value Multi-measure mappings.
     */
    @JvmName("hlxbxnwrkigtnigj")
    public suspend fun multiMeasureMappings(`value`: ScheduledQueryMultiMeasureMappingsArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.multiMeasureMappings = mapped
    }

    /**
     * @param argument Multi-measure mappings.
     */
    @JvmName("cekliikhdbbyorfp")
    public suspend fun multiMeasureMappings(argument: suspend ScheduledQueryMultiMeasureMappingsArgsBuilder.() -> Unit) {
        val toBeMapped = ScheduledQueryMultiMeasureMappingsArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.multiMeasureMappings = mapped
    }

    /**
     * @param value Name of Timestream table that the query result will be written to. The table should be within the same database that is provided in Timestream configuration.
     */
    @JvmName("aftnavqekpqktlpy")
    public suspend fun tableName(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tableName = mapped
    }

    /**
     * @param value Column from query result that should be used as the time column in destination table. Column type for this should be TIMESTAMP.
     */
    @JvmName("lhivcegblpofjnbx")
    public suspend fun timeColumn(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.timeColumn = mapped
    }

    internal fun build(): ScheduledQueryTimestreamConfigurationArgs =
        ScheduledQueryTimestreamConfigurationArgs(
            databaseName = databaseName ?: throw PulumiNullFieldException("databaseName"),
            dimensionMappings = dimensionMappings ?: throw PulumiNullFieldException("dimensionMappings"),
            measureNameColumn = measureNameColumn,
            mixedMeasureMappings = mixedMeasureMappings,
            multiMeasureMappings = multiMeasureMappings,
            tableName = tableName ?: throw PulumiNullFieldException("tableName"),
            timeColumn = timeColumn ?: throw PulumiNullFieldException("timeColumn"),
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy