commonMain.aws.sdk.kotlin.services.dataexchange.model.RedshiftDataShareDetails.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of dataexchange-jvm Show documentation
Show all versions of dataexchange-jvm Show documentation
The AWS Kotlin client for DataExchange
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.dataexchange.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Extra details specific to the affected scope in this Redshift data set.
*/
public class RedshiftDataShareDetails private constructor(builder: Builder) {
/**
* The ARN of the underlying Redshift data share that is being affected by this notification.
*/
public val arn: kotlin.String = requireNotNull(builder.arn) { "A non-null value must be provided for arn" }
/**
* The database name in the Redshift data share that is being affected by this notification.
*/
public val database: kotlin.String = requireNotNull(builder.database) { "A non-null value must be provided for database" }
/**
* A function name in the Redshift database that is being affected by this notification.
*/
public val function: kotlin.String? = builder.function
/**
* A schema name in the Redshift database that is being affected by this notification.
*/
public val schema: kotlin.String? = builder.schema
/**
* A table name in the Redshift database that is being affected by this notification.
*/
public val table: kotlin.String? = builder.table
/**
* A view name in the Redshift database that is being affected by this notification.
*/
public val view: kotlin.String? = builder.view
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.dataexchange.model.RedshiftDataShareDetails = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("RedshiftDataShareDetails(")
append("arn=$arn,")
append("database=$database,")
append("function=$function,")
append("schema=$schema,")
append("table=$table,")
append("view=$view")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = arn.hashCode()
result = 31 * result + (database.hashCode())
result = 31 * result + (function?.hashCode() ?: 0)
result = 31 * result + (schema?.hashCode() ?: 0)
result = 31 * result + (table?.hashCode() ?: 0)
result = 31 * result + (view?.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 RedshiftDataShareDetails
if (arn != other.arn) return false
if (database != other.database) return false
if (function != other.function) return false
if (schema != other.schema) return false
if (table != other.table) return false
if (view != other.view) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.dataexchange.model.RedshiftDataShareDetails = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The ARN of the underlying Redshift data share that is being affected by this notification.
*/
public var arn: kotlin.String? = null
/**
* The database name in the Redshift data share that is being affected by this notification.
*/
public var database: kotlin.String? = null
/**
* A function name in the Redshift database that is being affected by this notification.
*/
public var function: kotlin.String? = null
/**
* A schema name in the Redshift database that is being affected by this notification.
*/
public var schema: kotlin.String? = null
/**
* A table name in the Redshift database that is being affected by this notification.
*/
public var table: kotlin.String? = null
/**
* A view name in the Redshift database that is being affected by this notification.
*/
public var view: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.dataexchange.model.RedshiftDataShareDetails) : this() {
this.arn = x.arn
this.database = x.database
this.function = x.function
this.schema = x.schema
this.table = x.table
this.view = x.view
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.dataexchange.model.RedshiftDataShareDetails = RedshiftDataShareDetails(this)
internal fun correctErrors(): Builder {
if (arn == null) arn = ""
if (database == null) database = ""
return this
}
}
}