<gh_stars>0
# Generated from Enquestes.g by ANTLR 4.7.1
import sys
from io import StringIO
from typing.io import TextIO

from antlr4 import *


def serializedATN():
    with StringIO() as buf:
        buf.write("\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964\2\31")
        buf.write("\u00a4\b\1\4\2\t\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7")
        buf.write("\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13\t\13\4\f\t\f\4\r\t\r")
        buf.write("\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22\4\23")
        buf.write("\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27\4\30\t\30")
        buf.write("\3\2\3\2\6\2\64\n\2\r\2\16\2\65\3\3\3\3\7\3:\n\3\f\3\16")
        buf.write("\3=\13\3\3\4\3\4\6\4A\n\4\r\4\16\4B\3\5\3\5\6\5G\n\5\r")
        buf.write("\5\16\5H\3\6\3\6\6\6M\n\6\r\6\16\6N\3\7\3\7\3\b\3\b\3")
        buf.write("\t\3\t\3\n\3\n\3\13\3\13\3\f\3\f\3\f\3\f\3\f\3\f\3\f\3")
        buf.write("\f\3\f\3\r\3\r\3\r\3\r\3\r\3\16\3\16\3\16\3\16\3\16\3")
        buf.write("\16\3\16\3\16\3\16\3\17\3\17\3\17\3\17\3\17\3\17\3\17")
        buf.write("\3\17\3\17\3\20\3\20\3\20\3\20\3\20\3\20\3\20\3\20\3\20")
        buf.write("\3\20\3\20\3\20\3\21\3\21\3\22\3\22\3\22\3\23\6\23\u008d")
        buf.write("\n\23\r\23\16\23\u008e\3\24\3\24\3\24\3\24\3\25\6\25\u0096")
        buf.write("\n\25\r\25\16\25\u0097\3\26\3\26\3\27\3\27\3\30\6\30\u009f")
        buf.write("\n\30\r\30\16\30\u00a0\3\30\3\30\2\2\31\3\3\5\4\7\5\t")
        buf.write("\6\13\7\r\b\17\t\21\n\23\13\25\f\27\r\31\16\33\17\35\20")
        buf.write("\37\21!\22#\23%\24\'\25)\26+\27-\30/\31\3\2\5\3\2\62;")
        buf.write("\4\2C\\c|\4\2\f\f\"\"\2\u00ab\2\3\3\2\2\2\2\5\3\2\2\2")
        buf.write("\2\7\3\2\2\2\2\t\3\2\2\2\2\13\3\2\2\2\2\r\3\2\2\2\2\17")
        buf.write("\3\2\2\2\2\21\3\2\2\2\2\23\3\2\2\2\2\25\3\2\2\2\2\27\3")
        buf.write("\2\2\2\2\31\3\2\2\2\2\33\3\2\2\2\2\35\3\2\2\2\2\37\3\2")
        buf.write("\2\2\2!\3\2\2\2\2#\3\2\2\2\2%\3\2\2\2\2\'\3\2\2\2\2)\3")
        buf.write("\2\2\2\2+\3\2\2\2\2-\3\2\2\2\2/\3\2\2\2\3\61\3\2\2\2\5")
        buf.write("\67\3\2\2\2\7>\3\2\2\2\tD\3\2\2\2\13J\3\2\2\2\rP\3\2\2")
        buf.write("\2\17R\3\2\2\2\21T\3\2\2\2\23V\3\2\2\2\25X\3\2\2\2\27")
        buf.write("Z\3\2\2\2\31c\3\2\2\2\33h\3\2\2\2\35q\3\2\2\2\37z\3\2")
        buf.write("\2\2!\u0086\3\2\2\2#\u0088\3\2\2\2%\u008c\3\2\2\2\'\u0090")
        buf.write("\3\2\2\2)\u0095\3\2\2\2+\u0099\3\2\2\2-\u009b\3\2\2\2")
        buf.write("/\u009e\3\2\2\2\61\63\7C\2\2\62\64\t\2\2\2\63\62\3\2\2")
        buf.write("\2\64\65\3\2\2\2\65\63\3\2\2\2\65\66\3\2\2\2\66\4\3\2")
        buf.write("\2\2\67;\7G\2\28:\t\2\2\298\3\2\2\2:=\3\2\2\2;9\3\2\2")
        buf.write("\2;<\3\2\2\2<\6\3\2\2\2=;\3\2\2\2>@\7K\2\2?A\t\2\2\2@")
        buf.write("?\3\2\2\2AB\3\2\2\2B@\3\2\2\2BC\3\2\2\2C\b\3\2\2\2DF\7")
        buf.write("T\2\2EG\t\2\2\2FE\3\2\2\2GH\3\2\2\2HF\3\2\2\2HI\3\2\2")
        buf.write("\2I\n\3\2\2\2JL\7R\2\2KM\t\2\2\2LK\3\2\2\2MN\3\2\2\2N")
        buf.write("L\3\2\2\2NO\3\2\2\2O\f\3\2\2\2PQ\7.\2\2Q\16\3\2\2\2RS")
        buf.write("\7]\2\2S\20\3\2\2\2TU\7_\2\2U\22\3\2\2\2VW\7*\2\2W\24")
        buf.write("\3\2\2\2XY\7+\2\2Y\26\3\2\2\2Z[\7G\2\2[\\\7P\2\2\\]\7")
        buf.write("S\2\2]^\7W\2\2^_\7G\2\2_`\7U\2\2`a\7V\2\2ab\7C\2\2b\30")
        buf.write("\3\2\2\2cd\7K\2\2de\7V\2\2ef\7G\2\2fg\7O\2\2g\32\3\2\2")
        buf.write("\2hi\7R\2\2ij\7T\2\2jk\7G\2\2kl\7I\2\2lm\7W\2\2mn\7P\2")
        buf.write("\2no\7V\2\2op\7C\2\2p\34\3\2\2\2qr\7T\2\2rs\7G\2\2st\7")
        buf.write("U\2\2tu\7R\2\2uv\7Q\2\2vw\7U\2\2wx\7V\2\2xy\7C\2\2y\36")
        buf.write("\3\2\2\2z{\7C\2\2{|\7N\2\2|}\7V\2\2}~\7G\2\2~\177\7T\2")
        buf.write("\2\177\u0080\7P\2\2\u0080\u0081\7C\2\2\u0081\u0082\7V")
        buf.write("\2\2\u0082\u0083\7K\2\2\u0083\u0084\7X\2\2\u0084\u0085")
        buf.write("\7C\2\2\u0085 \3\2\2\2\u0086\u0087\7=\2\2\u0087\"\3\2")
        buf.write("\2\2\u0088\u0089\7/\2\2\u0089\u008a\7@\2\2\u008a$\3\2")
        buf.write("\2\2\u008b\u008d\t\2\2\2\u008c\u008b\3\2\2\2\u008d\u008e")
        buf.write("\3\2\2\2\u008e\u008c\3\2\2\2\u008e\u008f\3\2\2\2\u008f")
        buf.write("&\3\2\2\2\u0090\u0091\7G\2\2\u0091\u0092\7P\2\2\u0092")
        buf.write("\u0093\7F\2\2\u0093(\3\2\2\2\u0094\u0096\t\3\2\2\u0095")
        buf.write("\u0094\3\2\2\2\u0096\u0097\3\2\2\2\u0097\u0095\3\2\2\2")
        buf.write("\u0097\u0098\3\2\2\2\u0098*\3\2\2\2\u0099\u009a\7<\2\2")
        buf.write("\u009a,\3\2\2\2\u009b\u009c\7A\2\2\u009c.\3\2\2\2\u009d")
        buf.write("\u009f\t\4\2\2\u009e\u009d\3\2\2\2\u009f\u00a0\3\2\2\2")
        buf.write("\u00a0\u009e\3\2\2\2\u00a0\u00a1\3\2\2\2\u00a1\u00a2\3")
        buf.write("\2\2\2\u00a2\u00a3\b\30\2\2\u00a3\60\3\2\2\2\13\2\65;")
        buf.write("BHN\u008e\u0097\u00a0\3\b\2\2")
        return buf.getvalue()


class EnquestesLexer(Lexer):
    atn = ATNDeserializer().deserialize(serializedATN())

    decisionsToDFA = [DFA(ds, i) for i, ds in enumerate(atn.decisionToState)]

    AID = 1
    EID = 2
    IID = 3
    RID = 4
    PID = 5
    COMA = 6
    CE = 7
    CD = 8
    PE = 9
    PR = 10
    ENQUESTA = 11
    ELEMENT = 12
    PREGUNTA = 13
    RESPOSTA = 14
    ALTERNATIVA = 15
    PUNTCOMA = 16
    FLETXA = 17
    NUMERO = 18
    FINAL = 19
    PARAULES = 20
    PUNTS = 21
    SIGNEPREGUNTA = 22
    WS = 23

    channelNames = [u"DEFAULT_TOKEN_CHANNEL", u"HIDDEN"]

    modeNames = ["DEFAULT_MODE"]

    literalNames = ["<INVALID>",
                    "','", "'['", "']'", "'('", "')'", "'ENQUESTA'", "'ITEM'", "'PREGUNTA'",
                    "'RESPOSTA'", "'ALTERNATIVA'", "';'", "'->'", "'END'", "':'",
                    "'?'"]

    symbolicNames = ["<INVALID>",
                     "AID", "EID", "IID", "RID", "PID", "COMA", "CE", "CD", "PE",
                     "PR", "ENQUESTA", "ELEMENT", "PREGUNTA", "RESPOSTA", "ALTERNATIVA",
                     "PUNTCOMA", "FLETXA", "NUMERO", "FINAL", "PARAULES", "PUNTS",
                     "SIGNEPREGUNTA", "WS"]

    ruleNames = ["AID", "EID", "IID", "RID", "PID", "COMA", "CE", "CD",
                 "PE", "PR", "ENQUESTA", "ELEMENT", "PREGUNTA", "RESPOSTA",
                 "ALTERNATIVA", "PUNTCOMA", "FLETXA", "NUMERO", "FINAL",
                 "PARAULES", "PUNTS", "SIGNEPREGUNTA", "WS"]

    grammarFileName = "Enquestes.g"

    def __init__(self, input=None, output: TextIO = sys.stdout):
        super().__init__(input, output)
        self.checkVersion("4.7.1")
        self._interp = LexerATNSimulator(self, self.atn, self.decisionsToDFA, PredictionContextCache())
        self._actions = None
        self._predicates = None
