
commonMain.aws.sdk.kotlin.services.qconnect.model.TextData.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.qconnect.model
/**
* Details about the source content text data.
*/
public class TextData private constructor(builder: Builder) {
/**
* The text of the document.
*/
public val excerpt: aws.sdk.kotlin.services.qconnect.model.DocumentText? = builder.excerpt
/**
* The text of the document.
*/
public val title: aws.sdk.kotlin.services.qconnect.model.DocumentText? = builder.title
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.qconnect.model.TextData = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("TextData(")
append("excerpt=$excerpt,")
append("title=$title")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = excerpt?.hashCode() ?: 0
result = 31 * result + (title?.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 TextData
if (excerpt != other.excerpt) return false
if (title != other.title) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.qconnect.model.TextData = Builder(this).apply(block).build()
public class Builder {
/**
* The text of the document.
*/
public var excerpt: aws.sdk.kotlin.services.qconnect.model.DocumentText? = null
/**
* The text of the document.
*/
public var title: aws.sdk.kotlin.services.qconnect.model.DocumentText? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.qconnect.model.TextData) : this() {
this.excerpt = x.excerpt
this.title = x.title
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.qconnect.model.TextData = TextData(this)
/**
* construct an [aws.sdk.kotlin.services.qconnect.model.DocumentText] inside the given [block]
*/
public fun excerpt(block: aws.sdk.kotlin.services.qconnect.model.DocumentText.Builder.() -> kotlin.Unit) {
this.excerpt = aws.sdk.kotlin.services.qconnect.model.DocumentText.invoke(block)
}
/**
* construct an [aws.sdk.kotlin.services.qconnect.model.DocumentText] inside the given [block]
*/
public fun title(block: aws.sdk.kotlin.services.qconnect.model.DocumentText.Builder.() -> kotlin.Unit) {
this.title = aws.sdk.kotlin.services.qconnect.model.DocumentText.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy