public class ParseException
extends java.lang.Exception
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
after
Last correct input before error occurs.
|
private int |
column
Error column.
|
private int |
line
Error line.
|
private static long |
serialVersionUID
The version identifier.
|
Constructor and Description |
---|
ParseException()
Default ctor.
|
ParseException(java.lang.String message)
Constructor with message.
|
ParseException(Token currentToken,
int[][] expectedTokenSequences,
java.lang.String[] tokenImage)
This constructor is used by the method "generateParseException"
in the generated parser.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getAfter()
Gets the last correct input.
|
int |
getColumn()
Gets the column number.
|
int |
getLine()
Gets the line number.
|
private static final long serialVersionUID
private java.lang.String after
private int line
private int column
public ParseException(Token currentToken, int[][] expectedTokenSequences, java.lang.String[] tokenImage)
currentToken
- This is the last token that has been consumed successfully. If
this object has been created due to a parse error, the token
followng this token will (therefore) be the first error token.expectedTokenSequences
- Each entry in this array is an array of integers. Each array
of integers represents a sequence of tokens (by their ordinal
values) that is expected at this point of the parse.tokenImage
- This is a reference to the "tokenImage" array of the generated
parser within which the parse error occurred. This array is
defined in the generated ...Constants interface.public ParseException()
public ParseException(java.lang.String message)