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

commonMain.aws.sdk.kotlin.services.iot.model.JobExecutionsRolloutConfig.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.iot.model



/**
 * Allows you to create a staged rollout of a job.
 */
public class JobExecutionsRolloutConfig private constructor(builder: Builder) {
    /**
     * The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
     */
    public val exponentialRate: aws.sdk.kotlin.services.iot.model.ExponentialRolloutRate? = builder.exponentialRate
    /**
     * The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
     */
    public val maximumPerMinute: kotlin.Int? = builder.maximumPerMinute

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

    override fun toString(): kotlin.String = buildString {
        append("JobExecutionsRolloutConfig(")
        append("exponentialRate=$exponentialRate,")
        append("maximumPerMinute=$maximumPerMinute")
        append(")")
    }

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

        if (exponentialRate != other.exponentialRate) return false
        if (maximumPerMinute != other.maximumPerMinute) return false

        return true
    }

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

    public class Builder {
        /**
         * The rate of increase for a job rollout. This parameter allows you to define an exponential rate for a job rollout.
         */
        public var exponentialRate: aws.sdk.kotlin.services.iot.model.ExponentialRolloutRate? = null
        /**
         * The maximum number of things that will be notified of a pending job, per minute. This parameter allows you to create a staged rollout.
         */
        public var maximumPerMinute: kotlin.Int? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.iot.model.JobExecutionsRolloutConfig) : this() {
            this.exponentialRate = x.exponentialRate
            this.maximumPerMinute = x.maximumPerMinute
        }

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy