| Separates lexer from parser rules. Provides token and ignored symbols
after construction, which can be used for LexerBuilder construction.
Example:
SyntaxSeparation separation = new SyntaxSeparation(new Syntax(myRules));
LexerBuilder builder = new LexerBuilder(separation.getLexerSyntax(), separation.getIgnoredSymbols());
Lexer lexer = builder.getLexer();
// when using the lexer standalone, you must put the token terminal symbols into it now:
lexer.setTerminals(separation.getTokenSymbols());
// when using a Parser the Parser will do this:
See Also: fri.patterns.interpreter.parsergenerator.lexer.LexerBuilder author: (c) 2002, Fritz Ritzberger |