commonMain.aws.sdk.kotlin.services.athena.model.CustomerContentEncryptionConfiguration.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of athena-jvm Show documentation
Show all versions of athena-jvm Show documentation
The AWS SDK for Kotlin client for Athena
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.athena.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Specifies the customer managed KMS key that is used to encrypt the user's data stores in Athena. When an Amazon Web Services managed key is used, this value is null. This setting does not apply to Athena SQL workgroups.
*/
public class CustomerContentEncryptionConfiguration private constructor(builder: Builder) {
/**
* The customer managed KMS key that is used to encrypt the user's data stores in Athena.
*/
public val kmsKey: kotlin.String = requireNotNull(builder.kmsKey) { "A non-null value must be provided for kmsKey" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.athena.model.CustomerContentEncryptionConfiguration = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CustomerContentEncryptionConfiguration(")
append("kmsKey=$kmsKey")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = kmsKey.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 CustomerContentEncryptionConfiguration
if (kmsKey != other.kmsKey) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.athena.model.CustomerContentEncryptionConfiguration = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The customer managed KMS key that is used to encrypt the user's data stores in Athena.
*/
public var kmsKey: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.athena.model.CustomerContentEncryptionConfiguration) : this() {
this.kmsKey = x.kmsKey
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.athena.model.CustomerContentEncryptionConfiguration = CustomerContentEncryptionConfiguration(this)
internal fun correctErrors(): Builder {
if (kmsKey == null) kmsKey = ""
return this
}
}
}