|
Absimpa v196 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
absimpa.ParseException
public class ParseException
The parser may throw a ParseException, but it does
not create it itself. Rather it will call
Lexer.parseException(Set) to rely on the lexer to create it with
the necessary bits of information.
Strictly speaking this exception should be yet another generic parameter to all the classes in this package, but that would make writing code that uses them even more ugly.
| Constructor Summary | |
|---|---|
ParseException(java.util.Set<?> expected,
java.lang.Enum<?> found)
|
|
| Method Summary | |
|---|---|
int |
getColumn()
|
java.util.Set<?> |
getExpectedTokenCodes()
|
java.lang.Enum<?> |
getFoundTokenCode()
|
int |
getLine()
|
java.lang.String |
getMessage()
creates a message from the fields set in this exception. |
java.lang.String |
getMoreInfo()
|
java.lang.String |
getSourceName()
|
java.lang.String |
getTokenText()
|
void |
setColumn(int column)
set number of the input column within the input line on which the parse error occurred. |
void |
setLine(int line)
set number of the input line (or anything resembling a line) on which the parse error occurred. |
void |
setMoreInfo(java.lang.String moreInfo)
|
void |
setSourceName(java.lang.String sourceName)
set the name of the source from which the line with the parse error was read. |
void |
setTokenText(java.lang.String tokenText)
sets a string representation of the token that caused the error. |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ParseException(java.util.Set<?> expected,
java.lang.Enum<?> found)
| Method Detail |
|---|
public java.lang.String getMessage()
getMessage in class java.lang.Throwablepublic java.util.Set<?> getExpectedTokenCodes()
public java.lang.Enum<?> getFoundTokenCode()
public int getColumn()
public void setColumn(int column)
set number of the input column within the input line on which the parse error occurred.
public int getLine()
public void setLine(int line)
set number of the input line (or anything resembling a line) on which the parse error occurred.
public java.lang.String getSourceName()
public void setSourceName(java.lang.String sourceName)
set the name of the source from which the line with the parse error was read.
public java.lang.String getTokenText()
public void setTokenText(java.lang.String tokenText)
sets a string representation of the token that caused the error.
public void setMoreInfo(java.lang.String moreInfo)
public java.lang.String getMoreInfo()
|
Absimpa v196 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||