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

commonMain.aws.sdk.kotlin.services.dynamodb.model.TransactWriteItemsResponse.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.dynamodb.model



public class TransactWriteItemsResponse private constructor(builder: Builder) {
    /**
     * The capacity units consumed by the entire `TransactWriteItems` operation. The values of the list are ordered according to the ordering of the `TransactItems` request parameter.
     */
    public val consumedCapacity: List? = builder.consumedCapacity
    /**
     * A list of tables that were processed by `TransactWriteItems` and, for each table, information about any item collections that were affected by individual `UpdateItem`, `PutItem`, or `DeleteItem` operations.
     */
    public val itemCollectionMetrics: Map>? = builder.itemCollectionMetrics

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

    override fun toString(): kotlin.String = buildString {
        append("TransactWriteItemsResponse(")
        append("consumedCapacity=$consumedCapacity,")
        append("itemCollectionMetrics=$itemCollectionMetrics")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = consumedCapacity?.hashCode() ?: 0
        result = 31 * result + (itemCollectionMetrics?.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 TransactWriteItemsResponse

        if (consumedCapacity != other.consumedCapacity) return false
        if (itemCollectionMetrics != other.itemCollectionMetrics) return false

        return true
    }

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

    public class Builder {
        /**
         * The capacity units consumed by the entire `TransactWriteItems` operation. The values of the list are ordered according to the ordering of the `TransactItems` request parameter.
         */
        public var consumedCapacity: List? = null
        /**
         * A list of tables that were processed by `TransactWriteItems` and, for each table, information about any item collections that were affected by individual `UpdateItem`, `PutItem`, or `DeleteItem` operations.
         */
        public var itemCollectionMetrics: Map>? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.dynamodb.model.TransactWriteItemsResponse) : this() {
            this.consumedCapacity = x.consumedCapacity
            this.itemCollectionMetrics = x.itemCollectionMetrics
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy