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

commonMain.aws.sdk.kotlin.services.servicequotas.model.ErrorCode.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.servicequotas.model

import kotlin.collections.List

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

    public object DependencyAccessDeniedError : aws.sdk.kotlin.services.servicequotas.model.ErrorCode() {
        override val value: kotlin.String = "DEPENDENCY_ACCESS_DENIED_ERROR"
        override fun toString(): kotlin.String = "DependencyAccessDeniedError"
    }

    public object DependencyServiceError : aws.sdk.kotlin.services.servicequotas.model.ErrorCode() {
        override val value: kotlin.String = "DEPENDENCY_SERVICE_ERROR"
        override fun toString(): kotlin.String = "DependencyServiceError"
    }

    public object DependencyThrottlingError : aws.sdk.kotlin.services.servicequotas.model.ErrorCode() {
        override val value: kotlin.String = "DEPENDENCY_THROTTLING_ERROR"
        override fun toString(): kotlin.String = "DependencyThrottlingError"
    }

    public object ServiceQuotaNotAvailableError : aws.sdk.kotlin.services.servicequotas.model.ErrorCode() {
        override val value: kotlin.String = "SERVICE_QUOTA_NOT_AVAILABLE_ERROR"
        override fun toString(): kotlin.String = "ServiceQuotaNotAvailableError"
    }

    public data class SdkUnknown(override val value: kotlin.String) : aws.sdk.kotlin.services.servicequotas.model.ErrorCode() {
        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.servicequotas.model.ErrorCode = when (value) {
            "DEPENDENCY_ACCESS_DENIED_ERROR" -> DependencyAccessDeniedError
            "DEPENDENCY_SERVICE_ERROR" -> DependencyServiceError
            "DEPENDENCY_THROTTLING_ERROR" -> DependencyThrottlingError
            "SERVICE_QUOTA_NOT_AVAILABLE_ERROR" -> ServiceQuotaNotAvailableError
            else -> SdkUnknown(value)
        }

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

        private val values: kotlin.collections.List = listOf(
            DependencyAccessDeniedError,
            DependencyServiceError,
            DependencyThrottlingError,
            ServiceQuotaNotAvailableError,
        )
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy