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

commonMain.aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.emr.model

import kotlin.collections.List

public sealed class ClusterStateChangeReasonCode {
    public abstract val value: kotlin.String

    public object AllStepsCompleted : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "ALL_STEPS_COMPLETED"
        override fun toString(): kotlin.String = "AllStepsCompleted"
    }

    public object BootstrapFailure : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "BOOTSTRAP_FAILURE"
        override fun toString(): kotlin.String = "BootstrapFailure"
    }

    public object InstanceFailure : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "INSTANCE_FAILURE"
        override fun toString(): kotlin.String = "InstanceFailure"
    }

    public object InstanceFleetTimeout : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "INSTANCE_FLEET_TIMEOUT"
        override fun toString(): kotlin.String = "InstanceFleetTimeout"
    }

    public object InternalError : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "INTERNAL_ERROR"
        override fun toString(): kotlin.String = "InternalError"
    }

    public object StepFailure : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "STEP_FAILURE"
        override fun toString(): kotlin.String = "StepFailure"
    }

    public object UserRequest : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "USER_REQUEST"
        override fun toString(): kotlin.String = "UserRequest"
    }

    public object ValidationError : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override val value: kotlin.String = "VALIDATION_ERROR"
        override fun toString(): kotlin.String = "ValidationError"
    }

    public data class SdkUnknown(override val value: kotlin.String) : aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode() {
        override fun toString(): kotlin.String = "SdkUnknown($value)"
    }

    public companion object {
        /**
         * Convert a raw value to one of the sealed variants or [SdkUnknown]
         */
        public fun fromValue(value: kotlin.String): aws.sdk.kotlin.services.emr.model.ClusterStateChangeReasonCode = when (value) {
            "ALL_STEPS_COMPLETED" -> AllStepsCompleted
            "BOOTSTRAP_FAILURE" -> BootstrapFailure
            "INSTANCE_FAILURE" -> InstanceFailure
            "INSTANCE_FLEET_TIMEOUT" -> InstanceFleetTimeout
            "INTERNAL_ERROR" -> InternalError
            "STEP_FAILURE" -> StepFailure
            "USER_REQUEST" -> UserRequest
            "VALIDATION_ERROR" -> ValidationError
            else -> SdkUnknown(value)
        }

        /**
         * Get a list of all possible variants
         */
        public fun values(): kotlin.collections.List = values

        private val values: kotlin.collections.List = listOf(
            AllStepsCompleted,
            BootstrapFailure,
            InstanceFailure,
            InstanceFleetTimeout,
            InternalError,
            StepFailure,
            UserRequest,
            ValidationError,
        )
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy