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

commonMain.aws.sdk.kotlin.services.healthlake.model.S3Configuration.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.healthlake.model



/**
 * The configuration of the S3 bucket for either an import or export job. This includes assigning permissions for access.
 */
public class S3Configuration private constructor(builder: Builder) {
    /**
     * The KMS key ID used to access the S3 bucket.
     */
    public val kmsKeyId: kotlin.String = requireNotNull(builder.kmsKeyId) { "A non-null value must be provided for kmsKeyId" }
    /**
     * The S3Uri is the user specified S3 location of the FHIR data to be imported into AWS HealthLake.
     */
    public val s3Uri: kotlin.String = requireNotNull(builder.s3Uri) { "A non-null value must be provided for s3Uri" }

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

    override fun toString(): kotlin.String = buildString {
        append("S3Configuration(")
        append("kmsKeyId=$kmsKeyId,")
        append("s3Uri=$s3Uri")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = kmsKeyId.hashCode()
        result = 31 * result + (s3Uri.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 S3Configuration

        if (kmsKeyId != other.kmsKeyId) return false
        if (s3Uri != other.s3Uri) return false

        return true
    }

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

    public class Builder {
        /**
         * The KMS key ID used to access the S3 bucket.
         */
        public var kmsKeyId: kotlin.String? = null
        /**
         * The S3Uri is the user specified S3 location of the FHIR data to be imported into AWS HealthLake.
         */
        public var s3Uri: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.healthlake.model.S3Configuration) : this() {
            this.kmsKeyId = x.kmsKeyId
            this.s3Uri = x.s3Uri
        }

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

        internal fun correctErrors(): Builder {
            if (kmsKeyId == null) kmsKeyId = ""
            if (s3Uri == null) s3Uri = ""
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy