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

commonMain.aws.sdk.kotlin.services.voiceid.model.EvaluateSessionRequest.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.voiceid.model

import aws.smithy.kotlin.runtime.SdkDsl

public class EvaluateSessionRequest private constructor(builder: Builder) {
    /**
     * The identifier of the domain where the session started.
     */
    public val domainId: kotlin.String = requireNotNull(builder.domainId) { "A non-null value must be provided for domainId" }
    /**
     * The session identifier, or name of the session, that you want to evaluate. In Voice ID integration, this is the Contact-Id.
     */
    public val sessionNameOrId: kotlin.String = requireNotNull(builder.sessionNameOrId) { "A non-null value must be provided for sessionNameOrId" }

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

    override fun toString(): kotlin.String = buildString {
        append("EvaluateSessionRequest(")
        append("domainId=$domainId,")
        append("sessionNameOrId=$sessionNameOrId")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = domainId.hashCode()
        result = 31 * result + (sessionNameOrId.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 EvaluateSessionRequest

        if (domainId != other.domainId) return false
        if (sessionNameOrId != other.sessionNameOrId) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The identifier of the domain where the session started.
         */
        public var domainId: kotlin.String? = null
        /**
         * The session identifier, or name of the session, that you want to evaluate. In Voice ID integration, this is the Contact-Id.
         */
        public var sessionNameOrId: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.voiceid.model.EvaluateSessionRequest) : this() {
            this.domainId = x.domainId
            this.sessionNameOrId = x.sessionNameOrId
        }

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

        internal fun correctErrors(): Builder {
            if (domainId == null) domainId = ""
            if (sessionNameOrId == null) sessionNameOrId = ""
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy