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

import typing

from ......core import enum

T_Result = typing.TypeVar("T_Result")


class AttachmentInclusion(enum.StrEnum):
    NOT_INCLUDED = "not_included"
    INCLUDED_ON_NEXT_SUBMISSION = "included_on_next_submission"
    INCLUDED_ON_ALL_SUBMISSIONS = "included_on_all_submissions"
    _UNKNOWN = "__ATTACHMENTINCLUSION_UNKNOWN__"
    """
    This member is used for forward compatibility. If the value is not recognized by the enum, it will be stored here, and the raw value is accessible through `.value`.
    """

    @classmethod
    def _missing_(cls, value: typing.Any) -> "AttachmentInclusion":
        unknown = cls._UNKNOWN
        unknown._value_ = value
        return unknown

    def visit(
        self,
        not_included: typing.Callable[[], T_Result],
        included_on_next_submission: typing.Callable[[], T_Result],
        included_on_all_submissions: typing.Callable[[], T_Result],
        _unknown_member: typing.Callable[[str], T_Result],
    ) -> T_Result:
        if self is AttachmentInclusion.NOT_INCLUDED:
            return not_included()
        if self is AttachmentInclusion.INCLUDED_ON_NEXT_SUBMISSION:
            return included_on_next_submission()
        if self is AttachmentInclusion.INCLUDED_ON_ALL_SUBMISSIONS:
            return included_on_all_submissions()
        return _unknown_member(self._value_)
