public class TokenStreamBasicFilter extends Object implements TokenStream, IASDebugStream
Modifier and Type | Field and Description |
---|---|
protected BitSet |
discardMask
The set of token types to discard
|
protected TokenStream |
input
The input stream
|
Constructor and Description |
---|
TokenStreamBasicFilter(TokenStream input) |
Modifier and Type | Method and Description |
---|---|
void |
discard(BitSet mask) |
void |
discard(int ttype) |
String |
getEntireText()
Returns the entire text input to the lexer.
|
TokenOffsetInfo |
getOffsetInfo(Token token)
Returns the offset information for the token
|
Token |
nextToken() |
protected BitSet discardMask
protected TokenStream input
public TokenStreamBasicFilter(TokenStream input)
public void discard(int ttype)
public void discard(BitSet mask)
public Token nextToken() throws TokenStreamException
nextToken
in interface TokenStream
TokenStreamException
public String getEntireText()
IASDebugStream
getEntireText
in interface IASDebugStream
null
, if error occured or System.in was used.public TokenOffsetInfo getOffsetInfo(Token token)
IASDebugStream
getOffsetInfo
in interface IASDebugStream
token
- the token whose information need to be retrievednull