# coding=utf-8
# --------------------------------------------------------------------------
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.0.6320, generator: {generator})
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

from enum import Enum, EnumMeta
from six import with_metaclass


class _CaseInsensitiveEnumMeta(EnumMeta):
    def __getitem__(self, name):
        return super().__getitem__(name.upper())

    def __getattr__(cls, name):
        """Return the enum member matching `name`
        We use __getattr__ instead of descriptors or inserting into the enum
        class' __dict__ in order to support `name` and `value` being both
        properties for enum members (which live in the class' __dict__) and
        enum members themselves.
        """
        try:
            return cls._member_map_[name.upper()]
        except KeyError:
            raise AttributeError(name)


class EpisodeFinishReason(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)):
    """Reason for episodeFinish"""

    INVALID = "Invalid"
    UNSPECIFIED = "Unspecified"
    LESSON_CHANGED = "LessonChanged"
    TERMINAL = "Terminal"
    INTERRUPTED = "Interrupted"
    INVALID_STATE_VALUE = "InvalidStateValue"
    INTERNAL_ERROR = "InternalError"
    EPISODE_COMPLETE = "EpisodeComplete"
    TRAINING_COMPLETE = "TrainingComplete"


class EventType(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)):
    """Type of Event as response to advance method."""

    UNSPECIFIED = "Unspecified"
    EPISODE_START = "EpisodeStart"
    EPISODE_STEP = "EpisodeStep"
    EPISODE_FINISH = "EpisodeFinish"
    IDLE = "Idle"
    UNREGISTER = "Unregister"


class PurposeTypesAction(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)):

    INACTIVE = "Inactive"
    DEBUG = "Debug"
    TRAIN = "Train"
    ASSESS = "Assess"


class SimulatorContextTypesDeploymentMode(
    with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)
):

    UNSPECIFIED = "Unspecified"
    HOSTED = "Hosted"
    TESTING = "Testing"


class SimulatorSessionTypesStatus(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)):

    DEREGISTERED = "Deregistered"
    ATTACHABLE = "Attachable"
    ATTACHED = "Attached"
    DETACHING = "Detaching"
    REJECTED = "Rejected"


class UnregisterReason(with_metaclass(_CaseInsensitiveEnumMeta, str, Enum)):
    """Reason for unregister event."""

    UNSPECIFIED = "Unspecified"
    FINISHED = "Finished"
    ERROR = "Error"
    NOT_FOUND = "NotFound"
