commonMain.aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTable.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cleanrooms-jvm Show documentation
Show all versions of cleanrooms-jvm Show documentation
The AWS SDK for Kotlin client for CleanRooms
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cleanrooms.model
import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant
/**
* A table that has been configured for use in a collaboration.
*/
public class ConfiguredTable private constructor(builder: Builder) {
/**
* The columns within the underlying Glue table that can be utilized within collaborations.
*/
public val allowedColumns: List = requireNotNull(builder.allowedColumns) { "A non-null value must be provided for allowedColumns" }
/**
* The analysis method for the configured table. The only valid value is currently `DIRECT_QUERY`.
*/
public val analysisMethod: aws.sdk.kotlin.services.cleanrooms.model.AnalysisMethod = requireNotNull(builder.analysisMethod) { "A non-null value must be provided for analysisMethod" }
/**
* The types of analysis rules associated with this configured table. Currently, only one analysis rule may be associated with a configured table.
*/
public val analysisRuleTypes: List = requireNotNull(builder.analysisRuleTypes) { "A non-null value must be provided for analysisRuleTypes" }
/**
* The unique ARN for the configured table.
*/
public val arn: kotlin.String = requireNotNull(builder.arn) { "A non-null value must be provided for arn" }
/**
* The time the configured table was created.
*/
public val createTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createTime) { "A non-null value must be provided for createTime" }
/**
* A description for the configured table.
*/
public val description: kotlin.String? = builder.description
/**
* The unique ID for the configured table.
*/
public val id: kotlin.String = requireNotNull(builder.id) { "A non-null value must be provided for id" }
/**
* A name for the configured table.
*/
public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
/**
* The Glue table that this configured table represents.
*/
public val tableReference: aws.sdk.kotlin.services.cleanrooms.model.TableReference? = builder.tableReference
/**
* The time the configured table was last updated
*/
public val updateTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.updateTime) { "A non-null value must be provided for updateTime" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTable = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ConfiguredTable(")
append("allowedColumns=$allowedColumns,")
append("analysisMethod=$analysisMethod,")
append("analysisRuleTypes=$analysisRuleTypes,")
append("arn=$arn,")
append("createTime=$createTime,")
append("description=$description,")
append("id=$id,")
append("name=$name,")
append("tableReference=$tableReference,")
append("updateTime=$updateTime")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = allowedColumns.hashCode()
result = 31 * result + (analysisMethod.hashCode())
result = 31 * result + (analysisRuleTypes.hashCode())
result = 31 * result + (arn.hashCode())
result = 31 * result + (createTime.hashCode())
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (id.hashCode())
result = 31 * result + (name.hashCode())
result = 31 * result + (tableReference?.hashCode() ?: 0)
result = 31 * result + (updateTime.hashCode())
return result
}
override fun equals(other: kotlin.Any?): kotlin.Boolean {
if (this === other) return true
if (other == null || this::class != other::class) return false
other as ConfiguredTable
if (allowedColumns != other.allowedColumns) return false
if (analysisMethod != other.analysisMethod) return false
if (analysisRuleTypes != other.analysisRuleTypes) return false
if (arn != other.arn) return false
if (createTime != other.createTime) return false
if (description != other.description) return false
if (id != other.id) return false
if (name != other.name) return false
if (tableReference != other.tableReference) return false
if (updateTime != other.updateTime) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTable = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The columns within the underlying Glue table that can be utilized within collaborations.
*/
public var allowedColumns: List? = null
/**
* The analysis method for the configured table. The only valid value is currently `DIRECT_QUERY`.
*/
public var analysisMethod: aws.sdk.kotlin.services.cleanrooms.model.AnalysisMethod? = null
/**
* The types of analysis rules associated with this configured table. Currently, only one analysis rule may be associated with a configured table.
*/
public var analysisRuleTypes: List? = null
/**
* The unique ARN for the configured table.
*/
public var arn: kotlin.String? = null
/**
* The time the configured table was created.
*/
public var createTime: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* A description for the configured table.
*/
public var description: kotlin.String? = null
/**
* The unique ID for the configured table.
*/
public var id: kotlin.String? = null
/**
* A name for the configured table.
*/
public var name: kotlin.String? = null
/**
* The Glue table that this configured table represents.
*/
public var tableReference: aws.sdk.kotlin.services.cleanrooms.model.TableReference? = null
/**
* The time the configured table was last updated
*/
public var updateTime: aws.smithy.kotlin.runtime.time.Instant? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTable) : this() {
this.allowedColumns = x.allowedColumns
this.analysisMethod = x.analysisMethod
this.analysisRuleTypes = x.analysisRuleTypes
this.arn = x.arn
this.createTime = x.createTime
this.description = x.description
this.id = x.id
this.name = x.name
this.tableReference = x.tableReference
this.updateTime = x.updateTime
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTable = ConfiguredTable(this)
internal fun correctErrors(): Builder {
if (allowedColumns == null) allowedColumns = emptyList()
if (analysisMethod == null) analysisMethod = AnalysisMethod.SdkUnknown("no value provided")
if (analysisRuleTypes == null) analysisRuleTypes = emptyList()
if (arn == null) arn = ""
if (createTime == null) createTime = Instant.fromEpochSeconds(0)
if (id == null) id = ""
if (name == null) name = ""
if (updateTime == null) updateTime = Instant.fromEpochSeconds(0)
return this
}
}
}