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

import enum
import typing

T_Result = typing.TypeVar("T_Result")


class SexualOrientation(str, enum.Enum):
    HETEROSEXUAL = "HETEROSEXUAL"
    HOMOSEXUAL = "HOMOSEXUAL"
    BISEXUAL = "BISEXUAL"
    TWO_SPIRIT = "TWO_SPIRIT"
    OTHER = "OTHER"
    UNKNOWN = "UNKNOWN"
    REFUSED = "REFUSED"

    def visit(
        self,
        heterosexual: typing.Callable[[], T_Result],
        homosexual: typing.Callable[[], T_Result],
        bisexual: typing.Callable[[], T_Result],
        two_spirit: typing.Callable[[], T_Result],
        other: typing.Callable[[], T_Result],
        unknown: typing.Callable[[], T_Result],
        refused: typing.Callable[[], T_Result],
    ) -> T_Result:
        if self is SexualOrientation.HETEROSEXUAL:
            return heterosexual()
        if self is SexualOrientation.HOMOSEXUAL:
            return homosexual()
        if self is SexualOrientation.BISEXUAL:
            return bisexual()
        if self is SexualOrientation.TWO_SPIRIT:
            return two_spirit()
        if self is SexualOrientation.OTHER:
            return other()
        if self is SexualOrientation.UNKNOWN:
            return unknown()
        if self is SexualOrientation.REFUSED:
            return refused()
