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

commonMain.aws.sdk.kotlin.services.comprehend.model.UpdateEndpointRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.comprehend.model

import aws.smithy.kotlin.runtime.SdkDsl

public class UpdateEndpointRequest private constructor(builder: Builder) {
    /**
     * Data access role ARN to use in case the new model is encrypted with a customer CMK.
     */
    public val desiredDataAccessRoleArn: kotlin.String? = builder.desiredDataAccessRoleArn
    /**
     * The desired number of inference units to be used by the model using this endpoint. Each inference unit represents of a throughput of 100 characters per second.
     */
    public val desiredInferenceUnits: kotlin.Int? = builder.desiredInferenceUnits
    /**
     * The ARN of the new model to use when updating an existing endpoint.
     */
    public val desiredModelArn: kotlin.String? = builder.desiredModelArn
    /**
     * The Amazon Resource Number (ARN) of the endpoint being updated.
     */
    public val endpointArn: kotlin.String? = builder.endpointArn
    /**
     * The Amazon Resource Number (ARN) of the flywheel
     */
    public val flywheelArn: kotlin.String? = builder.flywheelArn

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

    override fun toString(): kotlin.String = buildString {
        append("UpdateEndpointRequest(")
        append("desiredDataAccessRoleArn=$desiredDataAccessRoleArn,")
        append("desiredInferenceUnits=$desiredInferenceUnits,")
        append("desiredModelArn=$desiredModelArn,")
        append("endpointArn=$endpointArn,")
        append("flywheelArn=$flywheelArn")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = desiredDataAccessRoleArn?.hashCode() ?: 0
        result = 31 * result + (desiredInferenceUnits ?: 0)
        result = 31 * result + (desiredModelArn?.hashCode() ?: 0)
        result = 31 * result + (endpointArn?.hashCode() ?: 0)
        result = 31 * result + (flywheelArn?.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 UpdateEndpointRequest

        if (desiredDataAccessRoleArn != other.desiredDataAccessRoleArn) return false
        if (desiredInferenceUnits != other.desiredInferenceUnits) return false
        if (desiredModelArn != other.desiredModelArn) return false
        if (endpointArn != other.endpointArn) return false
        if (flywheelArn != other.flywheelArn) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * Data access role ARN to use in case the new model is encrypted with a customer CMK.
         */
        public var desiredDataAccessRoleArn: kotlin.String? = null
        /**
         * The desired number of inference units to be used by the model using this endpoint. Each inference unit represents of a throughput of 100 characters per second.
         */
        public var desiredInferenceUnits: kotlin.Int? = null
        /**
         * The ARN of the new model to use when updating an existing endpoint.
         */
        public var desiredModelArn: kotlin.String? = null
        /**
         * The Amazon Resource Number (ARN) of the endpoint being updated.
         */
        public var endpointArn: kotlin.String? = null
        /**
         * The Amazon Resource Number (ARN) of the flywheel
         */
        public var flywheelArn: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.comprehend.model.UpdateEndpointRequest) : this() {
            this.desiredDataAccessRoleArn = x.desiredDataAccessRoleArn
            this.desiredInferenceUnits = x.desiredInferenceUnits
            this.desiredModelArn = x.desiredModelArn
            this.endpointArn = x.endpointArn
            this.flywheelArn = x.flywheelArn
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy