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

commonMain.aws.sdk.kotlin.services.outposts.model.InstancesToExclude.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.outposts.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * User-specified instances that must not be stopped. These instances will not appear in the list of instances that Amazon Web Services recommends to stop in order to free up capacity.
 */
public class InstancesToExclude private constructor(builder: Builder) {
    /**
     * IDs of the accounts that own each instance that must not be stopped.
     */
    public val accountIds: List? = builder.accountIds
    /**
     * List of user-specified instances that must not be stopped.
     */
    public val instances: List? = builder.instances
    /**
     * Names of the services that own each instance that must not be stopped in order to free up the capacity needed to run the capacity task.
     */
    public val services: List? = builder.services

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

    override fun toString(): kotlin.String = buildString {
        append("InstancesToExclude(")
        append("accountIds=$accountIds,")
        append("instances=$instances,")
        append("services=$services")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = accountIds?.hashCode() ?: 0
        result = 31 * result + (instances?.hashCode() ?: 0)
        result = 31 * result + (services?.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 InstancesToExclude

        if (accountIds != other.accountIds) return false
        if (instances != other.instances) return false
        if (services != other.services) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * IDs of the accounts that own each instance that must not be stopped.
         */
        public var accountIds: List? = null
        /**
         * List of user-specified instances that must not be stopped.
         */
        public var instances: List? = null
        /**
         * Names of the services that own each instance that must not be stopped in order to free up the capacity needed to run the capacity task.
         */
        public var services: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.outposts.model.InstancesToExclude) : this() {
            this.accountIds = x.accountIds
            this.instances = x.instances
            this.services = x.services
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy