java.lang.Object
de.grogra.grammar.Tokenizer
- All Implemented Interfaces:
antlr.TokenStream
- Direct Known Subclasses:
DTDTokenizer,JavaTokenizer,LSYTokenizer,XLTokenizer
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intprotected final booleanstatic final intprotected final booleanstatic final intprotected final booleanstatic final intprotected final booleanstatic final intprotected final booleanstatic final I18NBundlestatic final intprotected final booleanprotected final booleanstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal voidfinal voidfinal voidfinal voidfinal voidfinal voidfinal voidconsume(int type) protected Tokenprotected voidcopyTokenTablesFrom(Tokenizer source) final floatgetFloat()final InputgetInput()final intgetInt()final NumberLiteralgetNumberToken(int allowedLiterals) final TokengetToken()protected booleanisIdentifierPart(char c) protected booleanisIdentifierStart(char c) protected booleanisWhitespace(char c) antlr.Tokenfinal voidreset()final voidfinal voidfinal voidfinal void
-
Field Details
-
I18N
-
EOL_IS_SIGNIFICANT
public static final int EOL_IS_SIGNIFICANT- See Also:
-
FLOAT_IS_DEFAULT
public static final int FLOAT_IS_DEFAULT- See Also:
-
MINUS_IS_SIGN
public static final int MINUS_IS_SIGN- See Also:
-
CREATE_TOKEN_LOCATOR
public static final int CREATE_TOKEN_LOCATOR- See Also:
-
EVALUATE_NUMBERS
public static final int EVALUATE_NUMBERS- See Also:
-
ENABLE_TYPE_SUFFIX
public static final int ENABLE_TYPE_SUFFIX- See Also:
-
UNICODE_ESCAPES
public static final int UNICODE_ESCAPES- See Also:
-
eolIsSignificant
protected final boolean eolIsSignificant -
floatIsDefault
protected final boolean floatIsDefault -
minusIsSign
protected final boolean minusIsSign -
createTokenLocator
protected final boolean createTokenLocator -
evaluateNumbers
protected final boolean evaluateNumbers -
enableTypeSuffix
protected final boolean enableTypeSuffix -
unicode
protected final boolean unicode
-
-
Constructor Details
-
Tokenizer
public Tokenizer(int flags)
-
-
Method Details
-
copyTokenTablesFrom
-
addToken
-
addToken
-
addToken
-
addToken
-
addToken
-
addToken
-
setInput
-
setSource
-
setSource
-
getInput
-
reset
public final void reset() -
isWhitespace
protected boolean isWhitespace(char c) -
isIdentifierStart
protected boolean isIdentifierStart(char c) -
isIdentifierPart
protected boolean isIdentifierPart(char c) -
convert
-
getToken
- Throws:
IOExceptionLexicalException
-
nextToken
public antlr.Token nextToken() throws antlr.TokenStreamException- Specified by:
nextTokenin interfaceantlr.TokenStream- Throws:
antlr.TokenStreamException
-
ungetToken
public final void ungetToken() -
getNumberToken
- Throws:
IOExceptionLexicalException
-
getInt
- Throws:
IOExceptionLexicalException
-
getFloat
- Throws:
IOExceptionLexicalException
-
consume
-