commonMain.aws.sdk.kotlin.services.pinpointemail.model.Destination.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pinpointemail-jvm Show documentation
Show all versions of pinpointemail-jvm Show documentation
The AWS SDK for Kotlin client for Pinpoint Email
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.pinpointemail.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* An object that describes the recipients for an email.
*/
public class Destination private constructor(builder: Builder) {
/**
* An array that contains the email addresses of the "BCC" (blind carbon copy) recipients for the email.
*/
public val bccAddresses: List? = builder.bccAddresses
/**
* An array that contains the email addresses of the "CC" (carbon copy) recipients for the email.
*/
public val ccAddresses: List? = builder.ccAddresses
/**
* An array that contains the email addresses of the "To" recipients for the email.
*/
public val toAddresses: List? = builder.toAddresses
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.pinpointemail.model.Destination = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("Destination(")
append("bccAddresses=$bccAddresses,")
append("ccAddresses=$ccAddresses,")
append("toAddresses=$toAddresses")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = bccAddresses?.hashCode() ?: 0
result = 31 * result + (ccAddresses?.hashCode() ?: 0)
result = 31 * result + (toAddresses?.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 Destination
if (bccAddresses != other.bccAddresses) return false
if (ccAddresses != other.ccAddresses) return false
if (toAddresses != other.toAddresses) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.pinpointemail.model.Destination = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* An array that contains the email addresses of the "BCC" (blind carbon copy) recipients for the email.
*/
public var bccAddresses: List? = null
/**
* An array that contains the email addresses of the "CC" (carbon copy) recipients for the email.
*/
public var ccAddresses: List? = null
/**
* An array that contains the email addresses of the "To" recipients for the email.
*/
public var toAddresses: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.pinpointemail.model.Destination) : this() {
this.bccAddresses = x.bccAddresses
this.ccAddresses = x.ccAddresses
this.toAddresses = x.toAddresses
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.pinpointemail.model.Destination = Destination(this)
internal fun correctErrors(): Builder {
return this
}
}
}