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

commonMain.aws.sdk.kotlin.services.eks.model.DeleteAddonRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.eks.model

import aws.smithy.kotlin.runtime.SdkDsl

public class DeleteAddonRequest private constructor(builder: Builder) {
    /**
     * The name of the add-on. The name must match one of the names returned by `ListAddons`[](https://docs.aws.amazon.com/eks/latest/APIReference/API_ListAddons.html).
     */
    public val addonName: kotlin.String? = builder.addonName
    /**
     * The name of your cluster.
     */
    public val clusterName: kotlin.String? = builder.clusterName
    /**
     * Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on. If an IAM account is associated with the add-on, it isn't removed.
     */
    public val preserve: kotlin.Boolean? = builder.preserve

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

    override fun toString(): kotlin.String = buildString {
        append("DeleteAddonRequest(")
        append("addonName=$addonName,")
        append("clusterName=$clusterName,")
        append("preserve=$preserve")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = addonName?.hashCode() ?: 0
        result = 31 * result + (clusterName?.hashCode() ?: 0)
        result = 31 * result + (preserve?.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 DeleteAddonRequest

        if (addonName != other.addonName) return false
        if (clusterName != other.clusterName) return false
        if (preserve != other.preserve) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The name of the add-on. The name must match one of the names returned by `ListAddons`[](https://docs.aws.amazon.com/eks/latest/APIReference/API_ListAddons.html).
         */
        public var addonName: kotlin.String? = null
        /**
         * The name of your cluster.
         */
        public var clusterName: kotlin.String? = null
        /**
         * Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on. If an IAM account is associated with the add-on, it isn't removed.
         */
        public var preserve: kotlin.Boolean? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.eks.model.DeleteAddonRequest) : this() {
            this.addonName = x.addonName
            this.clusterName = x.clusterName
            this.preserve = x.preserve
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy