Uses of Class
org.antlr.runtime.RecognitionException
-
Packages that use RecognitionException Package Description org.antlr.runtime org.antlr.runtime.debug org.antlr.runtime.tree -
-
Uses of RecognitionException in org.antlr.runtime
Subclasses of RecognitionException in org.antlr.runtime Modifier and Type Class Description classEarlyExitExceptionThe recognizer did not match anything for a (..)+ loop.classFailedPredicateExceptionA semantic predicate failed during validation.classMismatchedNotSetExceptionclassMismatchedRangeExceptionclassMismatchedSetExceptionclassMismatchedTokenExceptionA mismatched char or Token or tree nodeclassMismatchedTreeNodeExceptionclassMissingTokenExceptionWe were expecting a token but it's not found.classNoViableAltExceptionclassUnwantedTokenExceptionAn extra token while parsing a TokenStreamMethods in org.antlr.runtime with parameters of type RecognitionException Modifier and Type Method Description voidBaseRecognizer. displayRecognitionError(String[] tokenNames, RecognitionException e)StringBaseRecognizer. getErrorHeader(RecognitionException e)What is the error header, normally line/character position information?StringBaseRecognizer. getErrorMessage(RecognitionException e, String[] tokenNames)What error message should be generated for the various exception types? Not very object-oriented code, but I like having all error message generation within one method rather than spread among all of the exception classes.StringLexer. getErrorMessage(RecognitionException e, String[] tokenNames)protected ObjectBaseRecognizer. getMissingSymbol(IntStream input, RecognitionException e, int expectedTokenType, BitSet follow)Conjure up a missing token during error recovery.protected ObjectParser. getMissingSymbol(IntStream input, RecognitionException e, int expectedTokenType, BitSet follow)voidBaseRecognizer. recover(IntStream input, RecognitionException re)Recover from an error found on the input stream.voidLexer. recover(RecognitionException re)Lexers can normally match any char in it's vocabulary after matching a token, so do the easy thing and just kill a character and hope it all works out.ObjectBaseRecognizer. recoverFromMismatchedSet(IntStream input, RecognitionException e, BitSet follow)Not currently usedvoidBaseRecognizer. reportError(RecognitionException e)Report a recognition problem.voidLexer. reportError(RecognitionException e)Methods in org.antlr.runtime that throw RecognitionException Modifier and Type Method Description ObjectBaseRecognizer. match(IntStream input, int ttype, BitSet follow)Match current input symbol against ttype.abstract voidLexer. mTokens()This is the lexer entry point that sets instance var 'token'intDFA. predict(IntStream input)From the input stream, predict what alternative will succeed using this DFA (representing the covering regular approximation to the underlying CFL).ObjectBaseRecognizer. recoverFromMismatchedSet(IntStream input, RecognitionException e, BitSet follow)Not currently usedprotected ObjectBaseRecognizer. recoverFromMismatchedToken(IntStream input, int ttype, BitSet follow)Attempt to recover from a single missing or extra token. -
Uses of RecognitionException in org.antlr.runtime.debug
Methods in org.antlr.runtime.debug with parameters of type RecognitionException Modifier and Type Method Description ObjectDebugTreeAdaptor. errorNode(TokenStream input, Token start, Token stop, RecognitionException e)protected ObjectDebugTreeParser. getMissingSymbol(IntStream input, RecognitionException e, int expectedTokenType, BitSet follow)voidBlankDebugEventListener. recognitionException(RecognitionException e)voidDebugEventHub. recognitionException(RecognitionException e)voidDebugEventListener. recognitionException(RecognitionException e)A recognition exception occurred such as NoViableAltException.voidDebugEventRepeater. recognitionException(RecognitionException e)voidDebugEventSocketProxy. recognitionException(RecognitionException e)voidParseTreeBuilder. recognitionException(RecognitionException e)voidProfiler. recognitionException(RecognitionException e)voidDebugParser. reportError(RecognitionException e)voidDebugTreeParser. reportError(RecognitionException e) -
Uses of RecognitionException in org.antlr.runtime.tree
Fields in org.antlr.runtime.tree declared as RecognitionException Modifier and Type Field Description RecognitionExceptionCommonErrorNode. trappedExceptionMethods in org.antlr.runtime.tree with parameters of type RecognitionException Modifier and Type Method Description ObjectBaseTreeAdaptor. errorNode(TokenStream input, Token start, Token stop, RecognitionException e)create tree node that holds the start and stop tokens associated with an error.ObjectTreeAdaptor. errorNode(TokenStream input, Token start, Token stop, RecognitionException e)Return a tree node representing an error.StringTreeParser. getErrorHeader(RecognitionException e)Prefix error message with the grammar name because message is always intended for the programmer because the parser built the input tree not the user.StringTreeParser. getErrorMessage(RecognitionException e, String[] tokenNames)Tree parsers parse nodes they usually have a token object as payload.protected ObjectTreeParser. getMissingSymbol(IntStream input, RecognitionException e, int expectedTokenType, BitSet follow)Methods in org.antlr.runtime.tree that throw RecognitionException Modifier and Type Method Description voidTreeFilter. bottomup()ObjectTreeRewriter. bottomup()protected ObjectTreeParser. recoverFromMismatchedToken(IntStream input, int ttype, BitSet follow)We have DOWN/UP nodes in the stream that have no line info; override.voidTreeFilter.fptr. rule()ObjectTreeRewriter.fptr. rule()voidTreeFilter. topdown()ObjectTreeRewriter. topdown()Constructors in org.antlr.runtime.tree with parameters of type RecognitionException Constructor Description CommonErrorNode(TokenStream input, Token start, Token stop, RecognitionException e)
-