# This file was auto-generated by Fern from our API Definition.

import enum
import typing

T_Result = typing.TypeVar("T_Result")


class InferenceResponseStatus(str, enum.Enum):
    """
    An enumeration.
    """

    REQUEST_RECEIVED = "RequestReceived"
    PROCESSED = "Processed"
    COMPLETITION_ERROR = "CompletitionError"
    COMPLETITION_TIMEOUT = "CompletitionTimeout"

    def visit(
        self,
        request_received: typing.Callable[[], T_Result],
        processed: typing.Callable[[], T_Result],
        completition_error: typing.Callable[[], T_Result],
        completition_timeout: typing.Callable[[], T_Result],
    ) -> T_Result:
        if self is InferenceResponseStatus.REQUEST_RECEIVED:
            return request_received()
        if self is InferenceResponseStatus.PROCESSED:
            return processed()
        if self is InferenceResponseStatus.COMPLETITION_ERROR:
            return completition_error()
        if self is InferenceResponseStatus.COMPLETITION_TIMEOUT:
            return completition_timeout()
