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

commonMain.aws.sdk.kotlin.services.datasync.model.P95Metrics.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.datasync.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * The types of performance data that DataSync Discovery collects about an on-premises storage system resource.
 */
public class P95Metrics private constructor(builder: Builder) {
    /**
     * The IOPS peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
     */
    public val iops: aws.sdk.kotlin.services.datasync.model.Iops? = builder.iops
    /**
     * The latency peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
     */
    public val latency: aws.sdk.kotlin.services.datasync.model.Latency? = builder.latency
    /**
     * The throughput peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
     */
    public val throughput: aws.sdk.kotlin.services.datasync.model.Throughput? = builder.throughput

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

    override fun toString(): kotlin.String = buildString {
        append("P95Metrics(")
        append("iops=$iops,")
        append("latency=$latency,")
        append("throughput=$throughput")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = iops?.hashCode() ?: 0
        result = 31 * result + (latency?.hashCode() ?: 0)
        result = 31 * result + (throughput?.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 P95Metrics

        if (iops != other.iops) return false
        if (latency != other.latency) return false
        if (throughput != other.throughput) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The IOPS peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
         */
        public var iops: aws.sdk.kotlin.services.datasync.model.Iops? = null
        /**
         * The latency peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
         */
        public var latency: aws.sdk.kotlin.services.datasync.model.Latency? = null
        /**
         * The throughput peaks for an on-premises storage system resource. Each data point represents the 95th percentile peak value during a 1-hour interval.
         */
        public var throughput: aws.sdk.kotlin.services.datasync.model.Throughput? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.datasync.model.P95Metrics) : this() {
            this.iops = x.iops
            this.latency = x.latency
            this.throughput = x.throughput
        }

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

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

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy