public abstract class AbstractLexer extends Lexer
Because antlr4 does not support generating lexer with specified interface, we have to create a super class for it and implement the interface.
Fields inherited from class | Fields |
---|---|
class Lexer |
DEFAULT_MODE, MORE, SKIP, DEFAULT_TOKEN_CHANNEL, HIDDEN, MIN_CHAR_VALUE, MAX_CHAR_VALUE, _input, _token, _tokenStartCharIndex, _tokenStartLine, _tokenStartCharPositionInLine, _hitEOF, _channel, _type, _modeStack, _mode, _text, EOF |
class Recognizer |
EOF |
Constructor and description |
---|
AbstractLexer
(CharStream input) |
Type Params | Return Type | Name and description |
---|---|---|
|
PositionInfo |
genPositionInfo(int offset) |
|
void |
require(boolean condition, String msg, boolean toAttachPositionInfo) |
|
void |
require(boolean condition, String msg) |
|
void |
require(boolean condition, String msg, int offset, boolean toAttachPositionInfo) |
|
void |
require(boolean condition, String msg, int offset) |
|
void |
throwSyntaxError(String msg, int offset, boolean toAttachPositionInfo) |
Copyright © 2003-2018 The Apache Software Foundation. All rights reserved.