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

commonMain.aws.sdk.kotlin.services.kendra.model.ConflictingItem.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.kendra.model



/**
 * Information about a conflicting query used across different sets of featured results. When you create a featured results set, you must check that the queries are unique per featured results set for each index.
 */
public class ConflictingItem private constructor(builder: Builder) {
    /**
     * The text of the conflicting query.
     */
    public val queryText: kotlin.String? = builder.queryText
    /**
     * The identifier of the set of featured results that the conflicting query belongs to.
     */
    public val setId: kotlin.String? = builder.setId
    /**
     * The name for the set of featured results that the conflicting query belongs to.
     */
    public val setName: kotlin.String? = builder.setName

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

    override fun toString(): kotlin.String = buildString {
        append("ConflictingItem(")
        append("queryText=$queryText,")
        append("setId=$setId,")
        append("setName=$setName")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = queryText?.hashCode() ?: 0
        result = 31 * result + (setId?.hashCode() ?: 0)
        result = 31 * result + (setName?.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 ConflictingItem

        if (queryText != other.queryText) return false
        if (setId != other.setId) return false
        if (setName != other.setName) return false

        return true
    }

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

    public class Builder {
        /**
         * The text of the conflicting query.
         */
        public var queryText: kotlin.String? = null
        /**
         * The identifier of the set of featured results that the conflicting query belongs to.
         */
        public var setId: kotlin.String? = null
        /**
         * The name for the set of featured results that the conflicting query belongs to.
         */
        public var setName: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kendra.model.ConflictingItem) : this() {
            this.queryText = x.queryText
            this.setId = x.setId
            this.setName = x.setName
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy