# Generated from PW_explorer/Input_Parsers/Telingo_Parser/Antlr_Files/Telingo_Output.g4 by ANTLR 4.7.1
# encoding: utf-8
from antlr4 import *
from io import StringIO
from typing.io import TextIO
import sys

def serializedATN():
    with StringIO() as buf:
        buf.write("\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964\3\21")
        buf.write("}\4\2\t\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b")
        buf.write("\t\b\4\t\t\t\4\n\t\n\4\13\t\13\4\f\t\f\4\r\t\r\4\16\t")
        buf.write("\16\3\2\7\2\36\n\2\f\2\16\2!\13\2\3\2\5\2$\n\2\3\2\3\2")
        buf.write("\3\3\3\3\3\3\7\3+\n\3\f\3\16\3.\13\3\3\3\5\3\61\n\3\3")
        buf.write("\3\5\3\64\n\3\3\4\3\4\3\4\7\49\n\4\f\4\16\4<\13\4\3\5")
        buf.write("\3\5\3\5\3\5\3\5\5\5C\n\5\3\6\3\6\5\6G\n\6\3\6\3\6\7\6")
        buf.write("K\n\6\f\6\16\6N\13\6\3\6\3\6\5\6R\n\6\3\7\3\7\3\b\3\b")
        buf.write("\5\bX\n\b\3\b\5\b[\n\b\3\b\3\b\3\b\3\b\3\t\3\t\3\t\3\t")
        buf.write("\5\te\n\t\3\n\3\n\3\n\3\n\3\13\3\13\3\13\3\13\3\f\3\f")
        buf.write("\3\f\3\f\3\r\6\rt\n\r\r\r\16\ru\3\16\6\16y\n\16\r\16\16")
        buf.write("\16z\3\16\2\2\17\2\4\6\b\n\f\16\20\22\24\26\30\32\2\3")
        buf.write("\5\2\6\7\n\n\20\20\2~\2\37\3\2\2\2\4\'\3\2\2\2\6\65\3")
        buf.write("\2\2\2\b=\3\2\2\2\nL\3\2\2\2\fS\3\2\2\2\16U\3\2\2\2\20")
        buf.write("`\3\2\2\2\22f\3\2\2\2\24j\3\2\2\2\26n\3\2\2\2\30s\3\2")
        buf.write("\2\2\32x\3\2\2\2\34\36\5\4\3\2\35\34\3\2\2\2\36!\3\2\2")
        buf.write("\2\37\35\3\2\2\2\37 \3\2\2\2 #\3\2\2\2!\37\3\2\2\2\"$")
        buf.write("\7\17\2\2#\"\3\2\2\2#$\3\2\2\2$%\3\2\2\2%&\5\16\b\2&\3")
        buf.write("\3\2\2\2\'(\7\3\2\2(,\7\20\2\2)+\5\6\4\2*)\3\2\2\2+.\3")
        buf.write("\2\2\2,*\3\2\2\2,-\3\2\2\2-\60\3\2\2\2.,\3\2\2\2/\61\7")
        buf.write("\4\2\2\60/\3\2\2\2\60\61\3\2\2\2\61\63\3\2\2\2\62\64\7")
        buf.write("\20\2\2\63\62\3\2\2\2\63\64\3\2\2\2\64\5\3\2\2\2\65\66")
        buf.write("\7\5\2\2\66:\7\20\2\2\679\5\b\5\28\67\3\2\2\29<\3\2\2")
        buf.write("\2:8\3\2\2\2:;\3\2\2\2;\7\3\2\2\2<:\3\2\2\2=B\7\20\2\2")
        buf.write(">?\7\6\2\2?@\5\n\6\2@A\7\7\2\2AC\3\2\2\2B>\3\2\2\2BC\3")
        buf.write("\2\2\2C\t\3\2\2\2DG\5\f\7\2EG\5\b\5\2FD\3\2\2\2FE\3\2")
        buf.write("\2\2GH\3\2\2\2HI\7\b\2\2IK\3\2\2\2JF\3\2\2\2KN\3\2\2\2")
        buf.write("LJ\3\2\2\2LM\3\2\2\2MQ\3\2\2\2NL\3\2\2\2OR\5\f\7\2PR\5")
        buf.write("\b\5\2QO\3\2\2\2QP\3\2\2\2R\13\3\2\2\2ST\7\20\2\2T\r\3")
        buf.write("\2\2\2UW\5\20\t\2VX\5\22\n\2WV\3\2\2\2WX\3\2\2\2XZ\3\2")
        buf.write("\2\2Y[\5\24\13\2ZY\3\2\2\2Z[\3\2\2\2[\\\3\2\2\2\\]\5\26")
        buf.write("\f\2]^\5\30\r\2^_\5\32\16\2_\17\3\2\2\2`a\7\t\2\2ab\7")
        buf.write("\n\2\2bd\7\20\2\2ce\7\13\2\2dc\3\2\2\2de\3\2\2\2e\21\3")
        buf.write("\2\2\2fg\7\f\2\2gh\7\n\2\2hi\7\20\2\2i\23\3\2\2\2jk\7")
        buf.write("\r\2\2kl\7\n\2\2lm\7\20\2\2m\25\3\2\2\2no\7\16\2\2op\7")
        buf.write("\n\2\2pq\7\20\2\2q\27\3\2\2\2rt\t\2\2\2sr\3\2\2\2tu\3")
        buf.write("\2\2\2us\3\2\2\2uv\3\2\2\2v\31\3\2\2\2wy\t\2\2\2xw\3\2")
        buf.write("\2\2yz\3\2\2\2zx\3\2\2\2z{\3\2\2\2{\33\3\2\2\2\21\37#")
        buf.write(",\60\63:BFLQWZduz")
        return buf.getvalue()


class Telingo_OutputParser ( Parser ):

    grammarFileName = "Telingo_Output.g4"

    atn = ATNDeserializer().deserialize(serializedATN())

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

    sharedContextCache = PredictionContextCache()

    literalNames = [ "<INVALID>", "'Answer:'", "'Optimization:'", "'State'", 
                     "'('", "')'", "','", "'Models'", "':'", "'+'", "'Optimum'", 
                     "'Optimization'", "'Calls'" ]

    symbolicNames = [ "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "OPTIMUM_FOUND", "TEXT", "WHITESPACE" ]

    RULE_telingoOutput = 0
    RULE_pw = 1
    RULE_state_desc = 2
    RULE_fact = 3
    RULE_fact_content = 4
    RULE_fact_text = 5
    RULE_summary = 6
    RULE_models = 7
    RULE_optimum = 8
    RULE_optimization = 9
    RULE_calls = 10
    RULE_time = 11
    RULE_cpuTime = 12

    ruleNames =  [ "telingoOutput", "pw", "state_desc", "fact", "fact_content", 
                   "fact_text", "summary", "models", "optimum", "optimization", 
                   "calls", "time", "cpuTime" ]

    EOF = Token.EOF
    T__0=1
    T__1=2
    T__2=3
    T__3=4
    T__4=5
    T__5=6
    T__6=7
    T__7=8
    T__8=9
    T__9=10
    T__10=11
    T__11=12
    OPTIMUM_FOUND=13
    TEXT=14
    WHITESPACE=15

    def __init__(self, input:TokenStream, output:TextIO = sys.stdout):
        super().__init__(input, output)
        self.checkVersion("4.7.1")
        self._interp = ParserATNSimulator(self, self.atn, self.decisionsToDFA, self.sharedContextCache)
        self._predicates = None



    class TelingoOutputContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def summary(self):
            return self.getTypedRuleContext(Telingo_OutputParser.SummaryContext,0)


        def pw(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(Telingo_OutputParser.PwContext)
            else:
                return self.getTypedRuleContext(Telingo_OutputParser.PwContext,i)


        def OPTIMUM_FOUND(self):
            return self.getToken(Telingo_OutputParser.OPTIMUM_FOUND, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_telingoOutput

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterTelingoOutput" ):
                listener.enterTelingoOutput(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitTelingoOutput" ):
                listener.exitTelingoOutput(self)




    def telingoOutput(self):

        localctx = Telingo_OutputParser.TelingoOutputContext(self, self._ctx, self.state)
        self.enterRule(localctx, 0, self.RULE_telingoOutput)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 29
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==Telingo_OutputParser.T__0:
                self.state = 26
                self.pw()
                self.state = 31
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 33
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.OPTIMUM_FOUND:
                self.state = 32
                self.match(Telingo_OutputParser.OPTIMUM_FOUND)


            self.state = 35
            self.summary()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class PwContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self, i:int=None):
            if i is None:
                return self.getTokens(Telingo_OutputParser.TEXT)
            else:
                return self.getToken(Telingo_OutputParser.TEXT, i)

        def state_desc(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(Telingo_OutputParser.State_descContext)
            else:
                return self.getTypedRuleContext(Telingo_OutputParser.State_descContext,i)


        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_pw

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterPw" ):
                listener.enterPw(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitPw" ):
                listener.exitPw(self)




    def pw(self):

        localctx = Telingo_OutputParser.PwContext(self, self._ctx, self.state)
        self.enterRule(localctx, 2, self.RULE_pw)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 37
            self.match(Telingo_OutputParser.T__0)
            self.state = 38
            self.match(Telingo_OutputParser.TEXT)
            self.state = 42
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==Telingo_OutputParser.T__2:
                self.state = 39
                self.state_desc()
                self.state = 44
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 46
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.T__1:
                self.state = 45
                self.match(Telingo_OutputParser.T__1)


            self.state = 49
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.TEXT:
                self.state = 48
                self.match(Telingo_OutputParser.TEXT)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class State_descContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def fact(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(Telingo_OutputParser.FactContext)
            else:
                return self.getTypedRuleContext(Telingo_OutputParser.FactContext,i)


        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_state_desc

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterState_desc" ):
                listener.enterState_desc(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitState_desc" ):
                listener.exitState_desc(self)




    def state_desc(self):

        localctx = Telingo_OutputParser.State_descContext(self, self._ctx, self.state)
        self.enterRule(localctx, 4, self.RULE_state_desc)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 51
            self.match(Telingo_OutputParser.T__2)
            self.state = 52
            self.match(Telingo_OutputParser.TEXT)
            self.state = 56
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,5,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 53
                    self.fact() 
                self.state = 58
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,5,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class FactContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def fact_content(self):
            return self.getTypedRuleContext(Telingo_OutputParser.Fact_contentContext,0)


        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_fact

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterFact" ):
                listener.enterFact(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitFact" ):
                listener.exitFact(self)




    def fact(self):

        localctx = Telingo_OutputParser.FactContext(self, self._ctx, self.state)
        self.enterRule(localctx, 6, self.RULE_fact)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 59
            self.match(Telingo_OutputParser.TEXT)
            self.state = 64
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.T__3:
                self.state = 60
                self.match(Telingo_OutputParser.T__3)
                self.state = 61
                self.fact_content()
                self.state = 62
                self.match(Telingo_OutputParser.T__4)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class Fact_contentContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def fact_text(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(Telingo_OutputParser.Fact_textContext)
            else:
                return self.getTypedRuleContext(Telingo_OutputParser.Fact_textContext,i)


        def fact(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(Telingo_OutputParser.FactContext)
            else:
                return self.getTypedRuleContext(Telingo_OutputParser.FactContext,i)


        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_fact_content

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterFact_content" ):
                listener.enterFact_content(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitFact_content" ):
                listener.exitFact_content(self)




    def fact_content(self):

        localctx = Telingo_OutputParser.Fact_contentContext(self, self._ctx, self.state)
        self.enterRule(localctx, 8, self.RULE_fact_content)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 74
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,8,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 68
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,7,self._ctx)
                    if la_ == 1:
                        self.state = 66
                        self.fact_text()
                        pass

                    elif la_ == 2:
                        self.state = 67
                        self.fact()
                        pass


                    self.state = 70
                    self.match(Telingo_OutputParser.T__5) 
                self.state = 76
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,8,self._ctx)

            self.state = 79
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,9,self._ctx)
            if la_ == 1:
                self.state = 77
                self.fact_text()
                pass

            elif la_ == 2:
                self.state = 78
                self.fact()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class Fact_textContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_fact_text

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterFact_text" ):
                listener.enterFact_text(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitFact_text" ):
                listener.exitFact_text(self)




    def fact_text(self):

        localctx = Telingo_OutputParser.Fact_textContext(self, self._ctx, self.state)
        self.enterRule(localctx, 10, self.RULE_fact_text)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 81
            self.match(Telingo_OutputParser.TEXT)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SummaryContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def models(self):
            return self.getTypedRuleContext(Telingo_OutputParser.ModelsContext,0)


        def calls(self):
            return self.getTypedRuleContext(Telingo_OutputParser.CallsContext,0)


        def time(self):
            return self.getTypedRuleContext(Telingo_OutputParser.TimeContext,0)


        def cpuTime(self):
            return self.getTypedRuleContext(Telingo_OutputParser.CpuTimeContext,0)


        def optimum(self):
            return self.getTypedRuleContext(Telingo_OutputParser.OptimumContext,0)


        def optimization(self):
            return self.getTypedRuleContext(Telingo_OutputParser.OptimizationContext,0)


        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_summary

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterSummary" ):
                listener.enterSummary(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitSummary" ):
                listener.exitSummary(self)




    def summary(self):

        localctx = Telingo_OutputParser.SummaryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 12, self.RULE_summary)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 83
            self.models()
            self.state = 85
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.T__9:
                self.state = 84
                self.optimum()


            self.state = 88
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.T__10:
                self.state = 87
                self.optimization()


            self.state = 90
            self.calls()
            self.state = 91
            self.time()
            self.state = 92
            self.cpuTime()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ModelsContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_models

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterModels" ):
                listener.enterModels(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitModels" ):
                listener.exitModels(self)




    def models(self):

        localctx = Telingo_OutputParser.ModelsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 14, self.RULE_models)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 94
            self.match(Telingo_OutputParser.T__6)
            self.state = 95
            self.match(Telingo_OutputParser.T__7)
            self.state = 96
            self.match(Telingo_OutputParser.TEXT)
            self.state = 98
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==Telingo_OutputParser.T__8:
                self.state = 97
                self.match(Telingo_OutputParser.T__8)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class OptimumContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_optimum

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterOptimum" ):
                listener.enterOptimum(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitOptimum" ):
                listener.exitOptimum(self)




    def optimum(self):

        localctx = Telingo_OutputParser.OptimumContext(self, self._ctx, self.state)
        self.enterRule(localctx, 16, self.RULE_optimum)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 100
            self.match(Telingo_OutputParser.T__9)
            self.state = 101
            self.match(Telingo_OutputParser.T__7)
            self.state = 102
            self.match(Telingo_OutputParser.TEXT)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class OptimizationContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_optimization

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterOptimization" ):
                listener.enterOptimization(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitOptimization" ):
                listener.exitOptimization(self)




    def optimization(self):

        localctx = Telingo_OutputParser.OptimizationContext(self, self._ctx, self.state)
        self.enterRule(localctx, 18, self.RULE_optimization)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 104
            self.match(Telingo_OutputParser.T__10)
            self.state = 105
            self.match(Telingo_OutputParser.T__7)
            self.state = 106
            self.match(Telingo_OutputParser.TEXT)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class CallsContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self):
            return self.getToken(Telingo_OutputParser.TEXT, 0)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_calls

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterCalls" ):
                listener.enterCalls(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitCalls" ):
                listener.exitCalls(self)




    def calls(self):

        localctx = Telingo_OutputParser.CallsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 20, self.RULE_calls)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 108
            self.match(Telingo_OutputParser.T__11)
            self.state = 109
            self.match(Telingo_OutputParser.T__7)
            self.state = 110
            self.match(Telingo_OutputParser.TEXT)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class TimeContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self, i:int=None):
            if i is None:
                return self.getTokens(Telingo_OutputParser.TEXT)
            else:
                return self.getToken(Telingo_OutputParser.TEXT, i)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_time

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterTime" ):
                listener.enterTime(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitTime" ):
                listener.exitTime(self)




    def time(self):

        localctx = Telingo_OutputParser.TimeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 22, self.RULE_time)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 113 
            self._errHandler.sync(self)
            _alt = 1
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt == 1:
                    self.state = 112
                    _la = self._input.LA(1)
                    if not((((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << Telingo_OutputParser.T__3) | (1 << Telingo_OutputParser.T__4) | (1 << Telingo_OutputParser.T__7) | (1 << Telingo_OutputParser.TEXT))) != 0)):
                        self._errHandler.recoverInline(self)
                    else:
                        self._errHandler.reportMatch(self)
                        self.consume()

                else:
                    raise NoViableAltException(self)
                self.state = 115 
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,13,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class CpuTimeContext(ParserRuleContext):

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TEXT(self, i:int=None):
            if i is None:
                return self.getTokens(Telingo_OutputParser.TEXT)
            else:
                return self.getToken(Telingo_OutputParser.TEXT, i)

        def getRuleIndex(self):
            return Telingo_OutputParser.RULE_cpuTime

        def enterRule(self, listener:ParseTreeListener):
            if hasattr( listener, "enterCpuTime" ):
                listener.enterCpuTime(self)

        def exitRule(self, listener:ParseTreeListener):
            if hasattr( listener, "exitCpuTime" ):
                listener.exitCpuTime(self)




    def cpuTime(self):

        localctx = Telingo_OutputParser.CpuTimeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 24, self.RULE_cpuTime)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 118 
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while True:
                self.state = 117
                _la = self._input.LA(1)
                if not((((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << Telingo_OutputParser.T__3) | (1 << Telingo_OutputParser.T__4) | (1 << Telingo_OutputParser.T__7) | (1 << Telingo_OutputParser.TEXT))) != 0)):
                    self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 120 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if not ((((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << Telingo_OutputParser.T__3) | (1 << Telingo_OutputParser.T__4) | (1 << Telingo_OutputParser.T__7) | (1 << Telingo_OutputParser.TEXT))) != 0)):
                    break

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx





