Possible Duplicate:
A Java API to generate Java source files 开发者_StackOverflow社区
Is there a good library for generating Java source code (not bytecode)?
CodeModel and Eclipse JDT worked for this fellow, and he ultimately chose CodeModel.
Try this http://code.google.com/p/javaparser/ i use this to rewrite huge portions of my existing code base, also ASTs can be constructed with this and it is a readable wrapper written over eclipse core....
精彩评论