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

commonMain.aws.sdk.kotlin.services.voiceid.model.DeleteSpeakerRequest.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 DeleteSpeakerRequest private constructor(builder: Builder) {
    /**
     * The identifier of the domain that contains the speaker.
     */
    public val domainId: kotlin.String = requireNotNull(builder.domainId) { "A non-null value must be provided for domainId" }
    /**
     * The identifier of the speaker you want to delete.
     */
    public val speakerId: kotlin.String = requireNotNull(builder.speakerId) { "A non-null value must be provided for speakerId" }

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

    override fun toString(): kotlin.String = buildString {
        append("DeleteSpeakerRequest(")
        append("domainId=$domainId,")
        append("speakerId=*** Sensitive Data Redacted ***")
        append(")")
    }

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

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

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The identifier of the domain that contains the speaker.
         */
        public var domainId: kotlin.String? = null
        /**
         * The identifier of the speaker you want to delete.
         */
        public var speakerId: kotlin.String? = null

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy