CommonTokenStream constructor
CommonTokenStream(
- TokenSource tokenSource, [
- int channel = Token.DEFAULT_CHANNEL
Constructs a new CommonTokenStream using the specified token source and filtering tokens to the specified channel. Only tokens whose {@link Token#getChannel} matches channel or have the {@link Token#getType} equal to {@link Token#EOF} will be returned by the token stream lookahead methods.
@param tokenSource The token source. @param channel The channel to use for filtering tokens.
Implementation
CommonTokenStream(TokenSource tokenSource,
[this.channel = Token.DEFAULT_CHANNEL])
: super(tokenSource);