
commonMain.aws.sdk.kotlin.services.managedblockchainquery.model.BatchGetTokenBalanceResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.managedblockchainquery.model
public class BatchGetTokenBalanceResponse private constructor(builder: Builder) {
/**
* An array of `BatchGetTokenBalanceErrorItem` objects returned from the request.
*/
public val errors: List = requireNotNull(builder.errors) { "A non-null value must be provided for errors" }
/**
* An array of `BatchGetTokenBalanceOutputItem` objects returned by the response.
*/
public val tokenBalances: List = requireNotNull(builder.tokenBalances) { "A non-null value must be provided for tokenBalances" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.managedblockchainquery.model.BatchGetTokenBalanceResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("BatchGetTokenBalanceResponse(")
append("errors=$errors,")
append("tokenBalances=$tokenBalances")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = errors.hashCode()
result = 31 * result + (tokenBalances.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 BatchGetTokenBalanceResponse
if (errors != other.errors) return false
if (tokenBalances != other.tokenBalances) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.managedblockchainquery.model.BatchGetTokenBalanceResponse = Builder(this).apply(block).build()
public class Builder {
/**
* An array of `BatchGetTokenBalanceErrorItem` objects returned from the request.
*/
public var errors: List? = null
/**
* An array of `BatchGetTokenBalanceOutputItem` objects returned by the response.
*/
public var tokenBalances: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.managedblockchainquery.model.BatchGetTokenBalanceResponse) : this() {
this.errors = x.errors
this.tokenBalances = x.tokenBalances
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.managedblockchainquery.model.BatchGetTokenBalanceResponse = BatchGetTokenBalanceResponse(this)
internal fun correctErrors(): Builder {
if (errors == null) errors = emptyList()
if (tokenBalances == null) tokenBalances = emptyList()
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy