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

commonMain.aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTableSummary.kt Maven / Gradle / Ivy

There is a newer version: 1.3.35
Show newest version
// 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 configured table summary for the objects listed by the request.
 */
public class ConfiguredTableSummary private constructor(builder: Builder) {
    /**
     * The analysis method for the configured tables. 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.
     */
    public val analysisRuleTypes: List = requireNotNull(builder.analysisRuleTypes) { "A non-null value must be provided for analysisRuleTypes" }
    /**
     * The unique ARN of 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" }
    /**
     * The unique ID of the configured table.
     */
    public val id: kotlin.String = requireNotNull(builder.id) { "A non-null value must be provided for id" }
    /**
     * The name of the configured table.
     */
    public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
    /**
     * 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.ConfiguredTableSummary = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("ConfiguredTableSummary(")
        append("analysisMethod=$analysisMethod,")
        append("analysisRuleTypes=$analysisRuleTypes,")
        append("arn=$arn,")
        append("createTime=$createTime,")
        append("id=$id,")
        append("name=$name,")
        append("updateTime=$updateTime")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = analysisMethod.hashCode()
        result = 31 * result + (analysisRuleTypes.hashCode())
        result = 31 * result + (arn.hashCode())
        result = 31 * result + (createTime.hashCode())
        result = 31 * result + (id.hashCode())
        result = 31 * result + (name.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 ConfiguredTableSummary

        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 (id != other.id) return false
        if (name != other.name) return false
        if (updateTime != other.updateTime) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTableSummary = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * The analysis method for the configured tables. 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.
         */
        public var analysisRuleTypes: List? = null
        /**
         * The unique ARN of 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
        /**
         * The unique ID of the configured table.
         */
        public var id: kotlin.String? = null
        /**
         * The name of the configured table.
         */
        public var name: kotlin.String? = 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.ConfiguredTableSummary) : this() {
            this.analysisMethod = x.analysisMethod
            this.analysisRuleTypes = x.analysisRuleTypes
            this.arn = x.arn
            this.createTime = x.createTime
            this.id = x.id
            this.name = x.name
            this.updateTime = x.updateTime
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.cleanrooms.model.ConfiguredTableSummary = ConfiguredTableSummary(this)

        internal fun correctErrors(): Builder {
            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
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy