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

commonMain.aws.sdk.kotlin.services.bedrock.model.CreateProvisionedModelThroughputRequest.kt Maven / Gradle / Ivy

There is a newer version: 1.4.1
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.bedrock.model



public class CreateProvisionedModelThroughputRequest private constructor(builder: Builder) {
    /**
     * Unique token value that you can provide. If this token matches a previous request, Bedrock ignores the request, but does not return an error.
     */
    public val clientRequestToken: kotlin.String? = builder.clientRequestToken
    /**
     * Commitment duration requested for the provisioned throughput.
     */
    public val commitmentDuration: aws.sdk.kotlin.services.bedrock.model.CommitmentDuration? = builder.commitmentDuration
    /**
     * Name or ARN of the model to associate with this provisioned throughput.
     */
    public val modelId: kotlin.String? = builder.modelId
    /**
     * Number of model units to allocate.
     */
    public val modelUnits: kotlin.Int? = builder.modelUnits
    /**
     * Unique name for this provisioned throughput.
     */
    public val provisionedModelName: kotlin.String? = builder.provisionedModelName
    /**
     * Tags to associate with this provisioned throughput.
     */
    public val tags: List? = builder.tags

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

    override fun toString(): kotlin.String = buildString {
        append("CreateProvisionedModelThroughputRequest(")
        append("clientRequestToken=$clientRequestToken,")
        append("commitmentDuration=$commitmentDuration,")
        append("modelId=$modelId,")
        append("modelUnits=$modelUnits,")
        append("provisionedModelName=$provisionedModelName,")
        append("tags=$tags")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = clientRequestToken?.hashCode() ?: 0
        result = 31 * result + (commitmentDuration?.hashCode() ?: 0)
        result = 31 * result + (modelId?.hashCode() ?: 0)
        result = 31 * result + (modelUnits ?: 0)
        result = 31 * result + (provisionedModelName?.hashCode() ?: 0)
        result = 31 * result + (tags?.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 CreateProvisionedModelThroughputRequest

        if (clientRequestToken != other.clientRequestToken) return false
        if (commitmentDuration != other.commitmentDuration) return false
        if (modelId != other.modelId) return false
        if (modelUnits != other.modelUnits) return false
        if (provisionedModelName != other.provisionedModelName) return false
        if (tags != other.tags) return false

        return true
    }

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

    public class Builder {
        /**
         * Unique token value that you can provide. If this token matches a previous request, Bedrock ignores the request, but does not return an error.
         */
        public var clientRequestToken: kotlin.String? = null
        /**
         * Commitment duration requested for the provisioned throughput.
         */
        public var commitmentDuration: aws.sdk.kotlin.services.bedrock.model.CommitmentDuration? = null
        /**
         * Name or ARN of the model to associate with this provisioned throughput.
         */
        public var modelId: kotlin.String? = null
        /**
         * Number of model units to allocate.
         */
        public var modelUnits: kotlin.Int? = null
        /**
         * Unique name for this provisioned throughput.
         */
        public var provisionedModelName: kotlin.String? = null
        /**
         * Tags to associate with this provisioned throughput.
         */
        public var tags: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.bedrock.model.CreateProvisionedModelThroughputRequest) : this() {
            this.clientRequestToken = x.clientRequestToken
            this.commitmentDuration = x.commitmentDuration
            this.modelId = x.modelId
            this.modelUnits = x.modelUnits
            this.provisionedModelName = x.provisionedModelName
            this.tags = x.tags
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy