use of org.eclipse.xtext.parser.antlr.AbstractAntlrParser in project xtext-core by eclipse.
the class AbstractAntlrParserBasedTokenSourceProvider method createTokenSource.
@Override
public TokenSource createTokenSource(final CharStream stream) {
if ((this.parser instanceof AbstractAntlrParser)) {
return ((AbstractAntlrParser) this.parser).createLexer(stream);
}
StringConcatenation _builder = new StringConcatenation();
String _name = this.parser.getClass().getName();
_builder.append(_name);
_builder.append(" should be a subclass of ");
String _name_1 = AbstractAntlrParser.class.getName();
_builder.append(_name_1);
throw new IllegalStateException(_builder.toString());
}
Aggregations