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

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

There is a newer version: 1.3.31
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 analysis template.
 */
public class AnalysisTemplate private constructor(builder: Builder) {
    /**
     * The parameters of the analysis template.
     */
    public val analysisParameters: List? = builder.analysisParameters
    /**
     * The Amazon Resource Name (ARN) of the analysis template.
     */
    public val arn: kotlin.String = requireNotNull(builder.arn) { "A non-null value must be provided for arn" }
    /**
     * The unique ARN for the analysis template’s associated collaboration.
     */
    public val collaborationArn: kotlin.String = requireNotNull(builder.collaborationArn) { "A non-null value must be provided for collaborationArn" }
    /**
     * The unique ID for the associated collaboration of the analysis template.
     */
    public val collaborationId: kotlin.String = requireNotNull(builder.collaborationId) { "A non-null value must be provided for collaborationId" }
    /**
     * The time that the analysis template was created.
     */
    public val createTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createTime) { "A non-null value must be provided for createTime" }
    /**
     * The description of the analysis template.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The format of the analysis template.
     */
    public val format: aws.sdk.kotlin.services.cleanrooms.model.AnalysisFormat = requireNotNull(builder.format) { "A non-null value must be provided for format" }
    /**
     * The identifier for the analysis template.
     */
    public val id: kotlin.String = requireNotNull(builder.id) { "A non-null value must be provided for id" }
    /**
     * The Amazon Resource Name (ARN) of the member who created the analysis template.
     */
    public val membershipArn: kotlin.String = requireNotNull(builder.membershipArn) { "A non-null value must be provided for membershipArn" }
    /**
     * The identifier of a member who created the analysis template.
     */
    public val membershipId: kotlin.String = requireNotNull(builder.membershipId) { "A non-null value must be provided for membershipId" }
    /**
     * The name of the analysis template.
     */
    public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
    /**
     * The entire schema object.
     */
    public val schema: aws.sdk.kotlin.services.cleanrooms.model.AnalysisSchema? = builder.schema
    /**
     * The source of the analysis template.
     */
    public val source: aws.sdk.kotlin.services.cleanrooms.model.AnalysisSource? = builder.source
    /**
     * The time that the analysis template was last updated.
     */
    public val updateTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.updateTime) { "A non-null value must be provided for updateTime" }
    /**
     * Information about the validations performed on the analysis template.
     */
    public val validations: List? = builder.validations

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cleanrooms.model.AnalysisTemplate = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("AnalysisTemplate(")
        append("analysisParameters=*** Sensitive Data Redacted ***,")
        append("arn=$arn,")
        append("collaborationArn=$collaborationArn,")
        append("collaborationId=$collaborationId,")
        append("createTime=$createTime,")
        append("description=$description,")
        append("format=$format,")
        append("id=$id,")
        append("membershipArn=$membershipArn,")
        append("membershipId=$membershipId,")
        append("name=$name,")
        append("schema=$schema,")
        append("source=*** Sensitive Data Redacted ***,")
        append("updateTime=$updateTime,")
        append("validations=$validations")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = analysisParameters?.hashCode() ?: 0
        result = 31 * result + (arn.hashCode())
        result = 31 * result + (collaborationArn.hashCode())
        result = 31 * result + (collaborationId.hashCode())
        result = 31 * result + (createTime.hashCode())
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (format.hashCode())
        result = 31 * result + (id.hashCode())
        result = 31 * result + (membershipArn.hashCode())
        result = 31 * result + (membershipId.hashCode())
        result = 31 * result + (name.hashCode())
        result = 31 * result + (schema?.hashCode() ?: 0)
        result = 31 * result + (source?.hashCode() ?: 0)
        result = 31 * result + (updateTime.hashCode())
        result = 31 * result + (validations?.hashCode() ?: 0)
        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 AnalysisTemplate

        if (analysisParameters != other.analysisParameters) return false
        if (arn != other.arn) return false
        if (collaborationArn != other.collaborationArn) return false
        if (collaborationId != other.collaborationId) return false
        if (createTime != other.createTime) return false
        if (description != other.description) return false
        if (format != other.format) return false
        if (id != other.id) return false
        if (membershipArn != other.membershipArn) return false
        if (membershipId != other.membershipId) return false
        if (name != other.name) return false
        if (schema != other.schema) return false
        if (source != other.source) return false
        if (updateTime != other.updateTime) return false
        if (validations != other.validations) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The parameters of the analysis template.
         */
        public var analysisParameters: List? = null
        /**
         * The Amazon Resource Name (ARN) of the analysis template.
         */
        public var arn: kotlin.String? = null
        /**
         * The unique ARN for the analysis template’s associated collaboration.
         */
        public var collaborationArn: kotlin.String? = null
        /**
         * The unique ID for the associated collaboration of the analysis template.
         */
        public var collaborationId: kotlin.String? = null
        /**
         * The time that the analysis template was created.
         */
        public var createTime: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The description of the analysis template.
         */
        public var description: kotlin.String? = null
        /**
         * The format of the analysis template.
         */
        public var format: aws.sdk.kotlin.services.cleanrooms.model.AnalysisFormat? = null
        /**
         * The identifier for the analysis template.
         */
        public var id: kotlin.String? = null
        /**
         * The Amazon Resource Name (ARN) of the member who created the analysis template.
         */
        public var membershipArn: kotlin.String? = null
        /**
         * The identifier of a member who created the analysis template.
         */
        public var membershipId: kotlin.String? = null
        /**
         * The name of the analysis template.
         */
        public var name: kotlin.String? = null
        /**
         * The entire schema object.
         */
        public var schema: aws.sdk.kotlin.services.cleanrooms.model.AnalysisSchema? = null
        /**
         * The source of the analysis template.
         */
        public var source: aws.sdk.kotlin.services.cleanrooms.model.AnalysisSource? = null
        /**
         * The time that the analysis template was last updated.
         */
        public var updateTime: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * Information about the validations performed on the analysis template.
         */
        public var validations: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.cleanrooms.model.AnalysisTemplate) : this() {
            this.analysisParameters = x.analysisParameters
            this.arn = x.arn
            this.collaborationArn = x.collaborationArn
            this.collaborationId = x.collaborationId
            this.createTime = x.createTime
            this.description = x.description
            this.format = x.format
            this.id = x.id
            this.membershipArn = x.membershipArn
            this.membershipId = x.membershipId
            this.name = x.name
            this.schema = x.schema
            this.source = x.source
            this.updateTime = x.updateTime
            this.validations = x.validations
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.cleanrooms.model.AnalysisSchema] inside the given [block]
         */
        public fun schema(block: aws.sdk.kotlin.services.cleanrooms.model.AnalysisSchema.Builder.() -> kotlin.Unit) {
            this.schema = aws.sdk.kotlin.services.cleanrooms.model.AnalysisSchema.invoke(block)
        }

        internal fun correctErrors(): Builder {
            if (arn == null) arn = ""
            if (collaborationArn == null) collaborationArn = ""
            if (collaborationId == null) collaborationId = ""
            if (createTime == null) createTime = Instant.fromEpochSeconds(0)
            if (format == null) format = AnalysisFormat.SdkUnknown("no value provided")
            if (id == null) id = ""
            if (membershipArn == null) membershipArn = ""
            if (membershipId == null) membershipId = ""
            if (name == null) name = ""
            if (updateTime == null) updateTime = Instant.fromEpochSeconds(0)
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy