
commonMain.aws.sdk.kotlin.services.dynamodb.model.BatchStatementResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.dynamodb.model
/**
* A PartiQL batch statement response..
*/
public class BatchStatementResponse private constructor(builder: Builder) {
/**
* The error associated with a failed PartiQL batch statement.
*/
public val error: aws.sdk.kotlin.services.dynamodb.model.BatchStatementError? = builder.error
/**
* A DynamoDB item associated with a BatchStatementResponse
*/
public val item: Map? = builder.item
/**
* The table name associated with a failed PartiQL batch statement.
*/
public val tableName: kotlin.String? = builder.tableName
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.dynamodb.model.BatchStatementResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("BatchStatementResponse(")
append("error=$error,")
append("item=$item,")
append("tableName=$tableName")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = error?.hashCode() ?: 0
result = 31 * result + (item?.hashCode() ?: 0)
result = 31 * result + (tableName?.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 BatchStatementResponse
if (error != other.error) return false
if (item != other.item) return false
if (tableName != other.tableName) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.dynamodb.model.BatchStatementResponse = Builder(this).apply(block).build()
public class Builder {
/**
* The error associated with a failed PartiQL batch statement.
*/
public var error: aws.sdk.kotlin.services.dynamodb.model.BatchStatementError? = null
/**
* A DynamoDB item associated with a BatchStatementResponse
*/
public var item: Map? = null
/**
* The table name associated with a failed PartiQL batch statement.
*/
public var tableName: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.dynamodb.model.BatchStatementResponse) : this() {
this.error = x.error
this.item = x.item
this.tableName = x.tableName
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.dynamodb.model.BatchStatementResponse = BatchStatementResponse(this)
/**
* construct an [aws.sdk.kotlin.services.dynamodb.model.BatchStatementError] inside the given [block]
*/
public fun error(block: aws.sdk.kotlin.services.dynamodb.model.BatchStatementError.Builder.() -> kotlin.Unit) {
this.error = aws.sdk.kotlin.services.dynamodb.model.BatchStatementError.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy