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

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

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

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



/**
 * Provides the configuration information for your content sources, such as data sources, FAQs, and content indexed directly via [BatchPutDocument](https://docs.aws.amazon.com/kendra/latest/dg/API_BatchPutDocument.html).
 */
public class ContentSourceConfiguration private constructor(builder: Builder) {
    /**
     * The identifier of the data sources you want to use for your Amazon Kendra experience.
     */
    public val dataSourceIds: List? = builder.dataSourceIds
    /**
     * `TRUE` to use documents you indexed directly using the `BatchPutDocument` API.
     */
    public val directPutContent: kotlin.Boolean = builder.directPutContent
    /**
     * The identifier of the FAQs that you want to use for your Amazon Kendra experience.
     */
    public val faqIds: List? = builder.faqIds

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

    override fun toString(): kotlin.String = buildString {
        append("ContentSourceConfiguration(")
        append("dataSourceIds=$dataSourceIds,")
        append("directPutContent=$directPutContent,")
        append("faqIds=$faqIds")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = dataSourceIds?.hashCode() ?: 0
        result = 31 * result + (directPutContent.hashCode())
        result = 31 * result + (faqIds?.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 ContentSourceConfiguration

        if (dataSourceIds != other.dataSourceIds) return false
        if (directPutContent != other.directPutContent) return false
        if (faqIds != other.faqIds) return false

        return true
    }

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

    public class Builder {
        /**
         * The identifier of the data sources you want to use for your Amazon Kendra experience.
         */
        public var dataSourceIds: List? = null
        /**
         * `TRUE` to use documents you indexed directly using the `BatchPutDocument` API.
         */
        public var directPutContent: kotlin.Boolean = false
        /**
         * The identifier of the FAQs that you want to use for your Amazon Kendra experience.
         */
        public var faqIds: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kendra.model.ContentSourceConfiguration) : this() {
            this.dataSourceIds = x.dataSourceIds
            this.directPutContent = x.directPutContent
            this.faqIds = x.faqIds
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy