commonMain.aws.sdk.kotlin.services.wisdom.model.SearchSessionsResponse.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of wisdom-jvm Show documentation
Show all versions of wisdom-jvm Show documentation
The AWS SDK for Kotlin client for Wisdom
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.wisdom.model
import aws.smithy.kotlin.runtime.SdkDsl
public class SearchSessionsResponse private constructor(builder: Builder) {
/**
* If there are additional results, this is the token for the next set of results.
*/
public val nextToken: kotlin.String? = builder.nextToken
/**
* Summary information about the sessions.
*/
public val sessionSummaries: List = requireNotNull(builder.sessionSummaries) { "A non-null value must be provided for sessionSummaries" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.wisdom.model.SearchSessionsResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("SearchSessionsResponse(")
append("nextToken=$nextToken,")
append("sessionSummaries=$sessionSummaries")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = nextToken?.hashCode() ?: 0
result = 31 * result + (sessionSummaries.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 SearchSessionsResponse
if (nextToken != other.nextToken) return false
if (sessionSummaries != other.sessionSummaries) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.wisdom.model.SearchSessionsResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* If there are additional results, this is the token for the next set of results.
*/
public var nextToken: kotlin.String? = null
/**
* Summary information about the sessions.
*/
public var sessionSummaries: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.wisdom.model.SearchSessionsResponse) : this() {
this.nextToken = x.nextToken
this.sessionSummaries = x.sessionSummaries
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.wisdom.model.SearchSessionsResponse = SearchSessionsResponse(this)
internal fun correctErrors(): Builder {
if (sessionSummaries == null) sessionSummaries = emptyList()
return this
}
}
}