antlr
public class TokenStreamSelector extends Object implements TokenStream, IASDebugStream
| Field Summary | |
|---|---|
| protected TokenStream | input The currently-selected token stream input |
| protected Hashtable | inputStreamNames The set of inputs to the MUX |
| protected Stack | streamStack Used to track stack of input streams |
| Constructor Summary | |
|---|---|
| TokenStreamSelector() | |
| Method Summary | |
|---|---|
| void | addInputStream(TokenStream stream, String key) |
| TokenStream | getCurrentStream() Return the stream from tokens are being pulled at
the moment. |
| String | getEntireText() |
| TokenOffsetInfo | getOffsetInfo(Token token) |
| TokenStream | getStream(String sname) |
| Token | nextToken() |
| TokenStream | pop() |
| void | push(TokenStream stream) |
| void | push(String sname) |
| void | retry() Abort recognition of current Token and try again.
|
| void | select(TokenStream stream) Set the stream without pushing old stream |
| void | select(String sname) |