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

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

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

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



public class SubmitFeedbackRequest private constructor(builder: Builder) {
    /**
     * Tells Amazon Kendra that a particular search result link was chosen by the user.
     */
    public val clickFeedbackItems: List? = builder.clickFeedbackItems
    /**
     * The identifier of the index that was queried.
     */
    public val indexId: kotlin.String? = builder.indexId
    /**
     * The identifier of the specific query for which you are submitting feedback. The query ID is returned in the response to the `Query` API.
     */
    public val queryId: kotlin.String? = builder.queryId
    /**
     * Provides Amazon Kendra with relevant or not relevant feedback for whether a particular item was relevant to the search.
     */
    public val relevanceFeedbackItems: List? = builder.relevanceFeedbackItems

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

    override fun toString(): kotlin.String = buildString {
        append("SubmitFeedbackRequest(")
        append("clickFeedbackItems=$clickFeedbackItems,")
        append("indexId=$indexId,")
        append("queryId=$queryId,")
        append("relevanceFeedbackItems=$relevanceFeedbackItems")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = clickFeedbackItems?.hashCode() ?: 0
        result = 31 * result + (indexId?.hashCode() ?: 0)
        result = 31 * result + (queryId?.hashCode() ?: 0)
        result = 31 * result + (relevanceFeedbackItems?.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 SubmitFeedbackRequest

        if (clickFeedbackItems != other.clickFeedbackItems) return false
        if (indexId != other.indexId) return false
        if (queryId != other.queryId) return false
        if (relevanceFeedbackItems != other.relevanceFeedbackItems) return false

        return true
    }

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

    public class Builder {
        /**
         * Tells Amazon Kendra that a particular search result link was chosen by the user.
         */
        public var clickFeedbackItems: List? = null
        /**
         * The identifier of the index that was queried.
         */
        public var indexId: kotlin.String? = null
        /**
         * The identifier of the specific query for which you are submitting feedback. The query ID is returned in the response to the `Query` API.
         */
        public var queryId: kotlin.String? = null
        /**
         * Provides Amazon Kendra with relevant or not relevant feedback for whether a particular item was relevant to the search.
         */
        public var relevanceFeedbackItems: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kendra.model.SubmitFeedbackRequest) : this() {
            this.clickFeedbackItems = x.clickFeedbackItems
            this.indexId = x.indexId
            this.queryId = x.queryId
            this.relevanceFeedbackItems = x.relevanceFeedbackItems
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy