commonMain.aws.sdk.kotlin.services.cleanrooms.model.DifferentialPrivacyConfiguration.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
/**
* Specifies the unique identifier for your users.
*/
public class DifferentialPrivacyConfiguration private constructor(builder: Builder) {
/**
* The name of the column (such as user_id) that contains the unique identifier of your users whose privacy you want to protect. If you want to turn on differential privacy for two or more tables in a collaboration, you must configure the same column as the user identifier column in both analysis rules.
*/
public val columns: List = requireNotNull(builder.columns) { "A non-null value must be provided for columns" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cleanrooms.model.DifferentialPrivacyConfiguration = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DifferentialPrivacyConfiguration(")
append("columns=$columns")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = columns.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 DifferentialPrivacyConfiguration
if (columns != other.columns) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanrooms.model.DifferentialPrivacyConfiguration = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The name of the column (such as user_id) that contains the unique identifier of your users whose privacy you want to protect. If you want to turn on differential privacy for two or more tables in a collaboration, you must configure the same column as the user identifier column in both analysis rules.
*/
public var columns: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cleanrooms.model.DifferentialPrivacyConfiguration) : this() {
this.columns = x.columns
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cleanrooms.model.DifferentialPrivacyConfiguration = DifferentialPrivacyConfiguration(this)
internal fun correctErrors(): Builder {
if (columns == null) columns = emptyList()
return this
}
}
}