| java.lang.Object java.lang.Throwable java.lang.Error com.flexive.sqlParser.TokenMgrError
TokenMgrError | public class TokenMgrError extends Error (Code) | | Customized token error class.
author: Gregor Schober (gregor.schober@flexive.com), UCS - unique computing solutions gmbh (http://www.ucs.at) |
Inner Class :public static enum REASON | |
Field Summary | |
final static int | INVALID_LEXICAL_STATE Tried to change to an invalid lexical state. | final static int | LEXICAL_ERROR Lexical error occured. | final static int | LOOP_DETECTED Detected (and bailed out of) an infinite loop in the token manager. | final static int | STATIC_LEXER_ERROR An attempt wass made to create a second instance of a static token manager. | int | errorCode Indicates the reason why the exception is thrown. |
INVALID_LEXICAL_STATE | final static int INVALID_LEXICAL_STATE(Code) | | Tried to change to an invalid lexical state.
|
LEXICAL_ERROR | final static int LEXICAL_ERROR(Code) | | Lexical error occured.
|
LOOP_DETECTED | final static int LOOP_DETECTED(Code) | | Detected (and bailed out of) an infinite loop in the token manager.
|
STATIC_LEXER_ERROR | final static int STATIC_LEXER_ERROR(Code) | | An attempt wass made to create a second instance of a static token manager.
|
errorCode | int errorCode(Code) | | Indicates the reason why the exception is thrown. It will have
one of the above 4 values.
|
TokenMgrError | public TokenMgrError()(Code) | | Empty constructor
|
TokenMgrError | public TokenMgrError(String message, int reason)(Code) | | Constructor.
Parameters: message - the message Parameters: reason - the reason |
TokenMgrError | public TokenMgrError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar, int reason)(Code) | | Constructor.
Parameters: EOFSeen - indicates if EOF caused the lexicl error Parameters: lexState - lexical state in which this error occured Parameters: errorLine - line number when the error occured Parameters: errorColumn - column number when the error occured Parameters: errorAfter - prefix that was seen before this error occured Parameters: curChar - the offending character Parameters: reason - the reason |
LexicalError | protected static String LexicalError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar)(Code) | | Returns a detailed message for the Error when it is thrown by the
token manager to indicate a lexical error.
Parameters: EOFSeen - indicates if EOF caused the lexicl error Parameters: lexState - lexical state in which this error occured Parameters: errorLine - line number when the error occured Parameters: errorColumn - column number when the error occured Parameters: errorAfter - prefix that was seen before this error occured Parameters: curChar - the offending character the string |
addEscapes | protected static String addEscapes(String str)(Code) | | Replaces unprintable characters by their espaced (or unicode escaped)
equivalents in the given string
Parameters: str - the string to escape the escape string |
getCurChar | public char getCurChar()(Code) | | the offending character
the offending character |
getCurCharEscaped | public String getCurCharEscaped()(Code) | | The offending character as escaped String.
The function replaces unprintable characters by their espaced (or unicode escaped)
equivalents in the given string
the offending character |
getEofSeen | public boolean getEofSeen()(Code) | | indicates if EOF caused the lexicl error
true or false |
getErrorAfter | public String getErrorAfter()(Code) | | prefix that was seen before this error occured
prefix that was seen before this error occured |
getErrorColumn | public int getErrorColumn()(Code) | | column number when the error occured
column number when the error occured |
getErrorLine | public int getErrorLine()(Code) | | line number when the error occured
line number when the error occured |
getLexState | public int getLexState()(Code) | | lexical state in which this error occured.
lexical state in which this error occured |
getReason | public REASON getReason()(Code) | | Returns the error reason.
the error reason |
|
|