
commonMain.aws.sdk.kotlin.services.opensearchserverless.model.CapacityLimits.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.opensearchserverless.model
/**
* The maximum capacity limits for all OpenSearch Serverless collections, in OpenSearch Compute Units (OCUs). These limits are used to scale your collections based on the current workload. For more information, see [Managing capacity limits for Amazon OpenSearch Serverless](https://docs.aws.amazon.com/opensearch-service/latest/developerguide/serverless-scaling.html).
*/
public class CapacityLimits private constructor(builder: Builder) {
/**
* The maximum indexing capacity for collections.
*/
public val maxIndexingCapacityInOcu: kotlin.Int? = builder.maxIndexingCapacityInOcu
/**
* The maximum search capacity for collections.
*/
public val maxSearchCapacityInOcu: kotlin.Int? = builder.maxSearchCapacityInOcu
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.opensearchserverless.model.CapacityLimits = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CapacityLimits(")
append("maxIndexingCapacityInOcu=$maxIndexingCapacityInOcu,")
append("maxSearchCapacityInOcu=$maxSearchCapacityInOcu")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = maxIndexingCapacityInOcu ?: 0
result = 31 * result + (maxSearchCapacityInOcu ?: 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 CapacityLimits
if (maxIndexingCapacityInOcu != other.maxIndexingCapacityInOcu) return false
if (maxSearchCapacityInOcu != other.maxSearchCapacityInOcu) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.opensearchserverless.model.CapacityLimits = Builder(this).apply(block).build()
public class Builder {
/**
* The maximum indexing capacity for collections.
*/
public var maxIndexingCapacityInOcu: kotlin.Int? = null
/**
* The maximum search capacity for collections.
*/
public var maxSearchCapacityInOcu: kotlin.Int? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.opensearchserverless.model.CapacityLimits) : this() {
this.maxIndexingCapacityInOcu = x.maxIndexingCapacityInOcu
this.maxSearchCapacityInOcu = x.maxSearchCapacityInOcu
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.opensearchserverless.model.CapacityLimits = CapacityLimits(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy