com.pulumi.gcp.bigquery.kotlin.inputs.TableTableConstraintsForeignKeyArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gcp-kotlin Show documentation
Show all versions of pulumi-gcp-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gcp.bigquery.kotlin.inputs
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.bigquery.inputs.TableTableConstraintsForeignKeyArgs.builder
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.jvm.JvmName
/**
*
* @property columnReferences The pair of the foreign key column and primary key column.
* Structure is documented below.
* @property name Set only if the foreign key constraint is named.
* @property referencedTable The table that holds the primary key
* and is referenced by this foreign key.
* Structure is documented below.
*/
public data class TableTableConstraintsForeignKeyArgs(
public val columnReferences: Output,
public val name: Output? = null,
public val referencedTable: Output,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gcp.bigquery.inputs.TableTableConstraintsForeignKeyArgs =
com.pulumi.gcp.bigquery.inputs.TableTableConstraintsForeignKeyArgs.builder()
.columnReferences(columnReferences.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.name(name?.applyValue({ args0 -> args0 }))
.referencedTable(
referencedTable.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
).build()
}
/**
* Builder for [TableTableConstraintsForeignKeyArgs].
*/
@PulumiTagMarker
public class TableTableConstraintsForeignKeyArgsBuilder internal constructor() {
private var columnReferences: Output? = null
private var name: Output? = null
private var referencedTable: Output? = null
/**
* @param value The pair of the foreign key column and primary key column.
* Structure is documented below.
*/
@JvmName("qygwaxjtrmygfqkj")
public suspend fun columnReferences(`value`: Output) {
this.columnReferences = value
}
/**
* @param value Set only if the foreign key constraint is named.
*/
@JvmName("ixhmkjywknrdhtgf")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value The table that holds the primary key
* and is referenced by this foreign key.
* Structure is documented below.
*/
@JvmName("cgvdxebonsfonldm")
public suspend fun referencedTable(`value`: Output) {
this.referencedTable = value
}
/**
* @param value The pair of the foreign key column and primary key column.
* Structure is documented below.
*/
@JvmName("eiulxguemlhqdxvf")
public suspend fun columnReferences(`value`: TableTableConstraintsForeignKeyColumnReferencesArgs) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.columnReferences = mapped
}
/**
* @param argument The pair of the foreign key column and primary key column.
* Structure is documented below.
*/
@JvmName("hoccowrgcuflbxna")
public suspend fun columnReferences(argument: suspend TableTableConstraintsForeignKeyColumnReferencesArgsBuilder.() -> Unit) {
val toBeMapped = TableTableConstraintsForeignKeyColumnReferencesArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.columnReferences = mapped
}
/**
* @param value Set only if the foreign key constraint is named.
*/
@JvmName("erqrrtcjpwsecdjc")
public suspend fun name(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.name = mapped
}
/**
* @param value The table that holds the primary key
* and is referenced by this foreign key.
* Structure is documented below.
*/
@JvmName("gsnwtghtfyidogou")
public suspend fun referencedTable(`value`: TableTableConstraintsForeignKeyReferencedTableArgs) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.referencedTable = mapped
}
/**
* @param argument The table that holds the primary key
* and is referenced by this foreign key.
* Structure is documented below.
*/
@JvmName("ymnfqvoekdwihdyf")
public suspend fun referencedTable(argument: suspend TableTableConstraintsForeignKeyReferencedTableArgsBuilder.() -> Unit) {
val toBeMapped = TableTableConstraintsForeignKeyReferencedTableArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.referencedTable = mapped
}
internal fun build(): TableTableConstraintsForeignKeyArgs = TableTableConstraintsForeignKeyArgs(
columnReferences = columnReferences ?: throw PulumiNullFieldException("columnReferences"),
name = name,
referencedTable = referencedTable ?: throw PulumiNullFieldException("referencedTable"),
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy