Package org.antlr.runtime
Class UnwantedTokenException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.antlr.runtime.RecognitionException
-
- org.antlr.runtime.MismatchedTokenException
-
- org.antlr.runtime.UnwantedTokenException
-
- All Implemented Interfaces:
Serializable
public class UnwantedTokenException extends MismatchedTokenException
An extra token while parsing a TokenStream- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.antlr.runtime.MismatchedTokenException
expecting
-
Fields inherited from class org.antlr.runtime.RecognitionException
approximateLineInfo, c, charPositionInLine, index, input, line, node, token
-
-
Constructor Summary
Constructors Constructor Description UnwantedTokenException()
Used for remote debugger deserializationUnwantedTokenException(int expecting, IntStream input)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Token
getUnexpectedToken()
String
toString()
-
Methods inherited from class org.antlr.runtime.RecognitionException
extractInformationFromTreeNodeStream, getUnexpectedType
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-
Constructor Detail
-
UnwantedTokenException
public UnwantedTokenException()
Used for remote debugger deserialization
-
UnwantedTokenException
public UnwantedTokenException(int expecting, IntStream input)
-
-
Method Detail
-
getUnexpectedToken
public Token getUnexpectedToken()
-
toString
public String toString()
- Overrides:
toString
in classMismatchedTokenException
-
-