commonMain.aws.sdk.kotlin.services.cleanrooms.model.SchemaSummary.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
/**
* The schema summary for the objects listed by the request.
*/
public class SchemaSummary private constructor(builder: Builder) {
/**
* The analysis method for the associated schema. The only valid value is currently `DIRECT_QUERY`.
*/
public val analysisMethod: aws.sdk.kotlin.services.cleanrooms.model.AnalysisMethod? = builder.analysisMethod
/**
* The types of analysis rules that are associated with this schema object.
*/
public val analysisRuleTypes: List = requireNotNull(builder.analysisRuleTypes) { "A non-null value must be provided for analysisRuleTypes" }
/**
* The unique ARN for the collaboration that the schema belongs to.
*/
public val collaborationArn: kotlin.String = requireNotNull(builder.collaborationArn) { "A non-null value must be provided for collaborationArn" }
/**
* The unique ID for the collaboration that the schema belongs to.
*/
public val collaborationId: kotlin.String = requireNotNull(builder.collaborationId) { "A non-null value must be provided for collaborationId" }
/**
* The time the schema object was created.
*/
public val createTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createTime) { "A non-null value must be provided for createTime" }
/**
* The unique account ID for the Amazon Web Services account that owns the schema.
*/
public val creatorAccountId: kotlin.String = requireNotNull(builder.creatorAccountId) { "A non-null value must be provided for creatorAccountId" }
/**
* The name for the schema object.
*/
public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
/**
* The type of schema object. The only valid schema type is currently `TABLE`.
*/
public val type: aws.sdk.kotlin.services.cleanrooms.model.SchemaType = requireNotNull(builder.type) { "A non-null value must be provided for type" }
/**
* The time the schema object 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.SchemaSummary = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("SchemaSummary(")
append("analysisMethod=$analysisMethod,")
append("analysisRuleTypes=$analysisRuleTypes,")
append("collaborationArn=$collaborationArn,")
append("collaborationId=$collaborationId,")
append("createTime=$createTime,")
append("creatorAccountId=$creatorAccountId,")
append("name=$name,")
append("type=$type,")
append("updateTime=$updateTime")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = analysisMethod?.hashCode() ?: 0
result = 31 * result + (analysisRuleTypes.hashCode())
result = 31 * result + (collaborationArn.hashCode())
result = 31 * result + (collaborationId.hashCode())
result = 31 * result + (createTime.hashCode())
result = 31 * result + (creatorAccountId.hashCode())
result = 31 * result + (name.hashCode())
result = 31 * result + (type.hashCode())
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 SchemaSummary
if (analysisMethod != other.analysisMethod) return false
if (analysisRuleTypes != other.analysisRuleTypes) return false
if (collaborationArn != other.collaborationArn) return false
if (collaborationId != other.collaborationId) return false
if (createTime != other.createTime) return false
if (creatorAccountId != other.creatorAccountId) return false
if (name != other.name) return false
if (type != other.type) return false
if (updateTime != other.updateTime) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanrooms.model.SchemaSummary = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The analysis method for the associated schema. The only valid value is currently `DIRECT_QUERY`.
*/
public var analysisMethod: aws.sdk.kotlin.services.cleanrooms.model.AnalysisMethod? = null
/**
* The types of analysis rules that are associated with this schema object.
*/
public var analysisRuleTypes: List? = null
/**
* The unique ARN for the collaboration that the schema belongs to.
*/
public var collaborationArn: kotlin.String? = null
/**
* The unique ID for the collaboration that the schema belongs to.
*/
public var collaborationId: kotlin.String? = null
/**
* The time the schema object was created.
*/
public var createTime: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The unique account ID for the Amazon Web Services account that owns the schema.
*/
public var creatorAccountId: kotlin.String? = null
/**
* The name for the schema object.
*/
public var name: kotlin.String? = null
/**
* The type of schema object. The only valid schema type is currently `TABLE`.
*/
public var type: aws.sdk.kotlin.services.cleanrooms.model.SchemaType? = null
/**
* The time the schema object 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.SchemaSummary) : this() {
this.analysisMethod = x.analysisMethod
this.analysisRuleTypes = x.analysisRuleTypes
this.collaborationArn = x.collaborationArn
this.collaborationId = x.collaborationId
this.createTime = x.createTime
this.creatorAccountId = x.creatorAccountId
this.name = x.name
this.type = x.type
this.updateTime = x.updateTime
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cleanrooms.model.SchemaSummary = SchemaSummary(this)
internal fun correctErrors(): Builder {
if (analysisRuleTypes == null) analysisRuleTypes = emptyList()
if (collaborationArn == null) collaborationArn = ""
if (collaborationId == null) collaborationId = ""
if (createTime == null) createTime = Instant.fromEpochSeconds(0)
if (creatorAccountId == null) creatorAccountId = ""
if (name == null) name = ""
if (type == null) type = SchemaType.SdkUnknown("no value provided")
if (updateTime == null) updateTime = Instant.fromEpochSeconds(0)
return this
}
}
}