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

aws.sdk.kotlin.services.sagemaker.model.ModelQuality.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.sagemaker.model



/**
 * Model quality statistics and constraints.
 */
class ModelQuality private constructor(builder: Builder) {
    /**
     * Model quality constraints.
     */
    val constraints: aws.sdk.kotlin.services.sagemaker.model.MetricsSource? = builder.constraints
    /**
     * Model quality statistics.
     */
    val statistics: aws.sdk.kotlin.services.sagemaker.model.MetricsSource? = builder.statistics

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

    override fun toString(): kotlin.String = buildString {
        append("ModelQuality(")
        append("constraints=$constraints,")
        append("statistics=$statistics)")
    }

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

        if (constraints != other.constraints) return false
        if (statistics != other.statistics) return false

        return true
    }

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

    class Builder {
        /**
         * Model quality constraints.
         */
        var constraints: aws.sdk.kotlin.services.sagemaker.model.MetricsSource? = null
        /**
         * Model quality statistics.
         */
        var statistics: aws.sdk.kotlin.services.sagemaker.model.MetricsSource? = null

        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.sagemaker.model.ModelQuality) : this() {
            this.constraints = x.constraints
            this.statistics = x.statistics
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.sagemaker.model.MetricsSource] inside the given [block]
         */
        fun constraints(block: aws.sdk.kotlin.services.sagemaker.model.MetricsSource.Builder.() -> kotlin.Unit) {
            this.constraints = aws.sdk.kotlin.services.sagemaker.model.MetricsSource.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.sagemaker.model.MetricsSource] inside the given [block]
         */
        fun statistics(block: aws.sdk.kotlin.services.sagemaker.model.MetricsSource.Builder.() -> kotlin.Unit) {
            this.statistics = aws.sdk.kotlin.services.sagemaker.model.MetricsSource.invoke(block)
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy