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

commonMain.aws.sdk.kotlin.services.pinpointemail.model.IspPlacement.kt Maven / Gradle / Ivy

There is a newer version: 1.3.77
Show newest version
// 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 how email sent during the predictive inbox placement test was handled by a certain email provider.
 */
public class IspPlacement private constructor(builder: Builder) {
    /**
     * The name of the email provider that the inbox placement data applies to.
     */
    public val ispName: kotlin.String? = builder.ispName
    /**
     * An object that contains inbox placement metrics for a specific email provider.
     */
    public val placementStatistics: aws.sdk.kotlin.services.pinpointemail.model.PlacementStatistics? = builder.placementStatistics

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

    override fun toString(): kotlin.String = buildString {
        append("IspPlacement(")
        append("ispName=$ispName,")
        append("placementStatistics=$placementStatistics")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = ispName?.hashCode() ?: 0
        result = 31 * result + (placementStatistics?.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 IspPlacement

        if (ispName != other.ispName) return false
        if (placementStatistics != other.placementStatistics) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The name of the email provider that the inbox placement data applies to.
         */
        public var ispName: kotlin.String? = null
        /**
         * An object that contains inbox placement metrics for a specific email provider.
         */
        public var placementStatistics: aws.sdk.kotlin.services.pinpointemail.model.PlacementStatistics? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.pinpointemail.model.IspPlacement) : this() {
            this.ispName = x.ispName
            this.placementStatistics = x.placementStatistics
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.pinpointemail.model.PlacementStatistics] inside the given [block]
         */
        public fun placementStatistics(block: aws.sdk.kotlin.services.pinpointemail.model.PlacementStatistics.Builder.() -> kotlin.Unit) {
            this.placementStatistics = aws.sdk.kotlin.services.pinpointemail.model.PlacementStatistics.invoke(block)
        }

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy