Java generator based on ANTLR grammar