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

commonMain.aws.sdk.kotlin.services.connectcases.model.BatchPutFieldOptionsRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.connectcases.model



public class BatchPutFieldOptionsRequest private constructor(builder: Builder) {
    /**
     * The unique identifier of the Cases domain.
     */
    public val domainId: kotlin.String = requireNotNull(builder.domainId) { "A non-null value must be provided for domainId" }
    /**
     * The unique identifier of a field.
     */
    public val fieldId: kotlin.String = requireNotNull(builder.fieldId) { "A non-null value must be provided for fieldId" }
    /**
     * A list of `FieldOption` objects.
     */
    public val options: List = requireNotNull(builder.options) { "A non-null value must be provided for options" }

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

    override fun toString(): kotlin.String = buildString {
        append("BatchPutFieldOptionsRequest(")
        append("domainId=$domainId,")
        append("fieldId=$fieldId,")
        append("options=$options")
        append(")")
    }

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

        if (domainId != other.domainId) return false
        if (fieldId != other.fieldId) return false
        if (options != other.options) return false

        return true
    }

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

    public class Builder {
        /**
         * The unique identifier of the Cases domain.
         */
        public var domainId: kotlin.String? = null
        /**
         * The unique identifier of a field.
         */
        public var fieldId: kotlin.String? = null
        /**
         * A list of `FieldOption` objects.
         */
        public var options: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.connectcases.model.BatchPutFieldOptionsRequest) : this() {
            this.domainId = x.domainId
            this.fieldId = x.fieldId
            this.options = x.options
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy