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

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

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

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



/**
 * Represents the auto scaling configuration for a global table.
 */
public class TableAutoScalingDescription private constructor(builder: Builder) {
    /**
     * Represents replicas of the global table.
     */
    public val replicas: List? = builder.replicas
    /**
     * The name of the table.
     */
    public val tableName: kotlin.String? = builder.tableName
    /**
     * The current state of the table:
     * + `CREATING` - The table is being created.
     * + `UPDATING` - The table is being updated.
     * + `DELETING` - The table is being deleted.
     * + `ACTIVE` - The table is ready for use.
     */
    public val tableStatus: aws.sdk.kotlin.services.dynamodb.model.TableStatus? = builder.tableStatus

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

    override fun toString(): kotlin.String = buildString {
        append("TableAutoScalingDescription(")
        append("replicas=$replicas,")
        append("tableName=$tableName,")
        append("tableStatus=$tableStatus")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = replicas?.hashCode() ?: 0
        result = 31 * result + (tableName?.hashCode() ?: 0)
        result = 31 * result + (tableStatus?.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 TableAutoScalingDescription

        if (replicas != other.replicas) return false
        if (tableName != other.tableName) return false
        if (tableStatus != other.tableStatus) return false

        return true
    }

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

    public class Builder {
        /**
         * Represents replicas of the global table.
         */
        public var replicas: List? = null
        /**
         * The name of the table.
         */
        public var tableName: kotlin.String? = null
        /**
         * The current state of the table:
         * + `CREATING` - The table is being created.
         * + `UPDATING` - The table is being updated.
         * + `DELETING` - The table is being deleted.
         * + `ACTIVE` - The table is ready for use.
         */
        public var tableStatus: aws.sdk.kotlin.services.dynamodb.model.TableStatus? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.dynamodb.model.TableAutoScalingDescription) : this() {
            this.replicas = x.replicas
            this.tableName = x.tableName
            this.tableStatus = x.tableStatus
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy