I am looking for nice (java) code generation engine. I have found cglib but it is very poorly documented and I am not quite sure that it can generate actual java classes (files) and only dynamic classes. If I am wrong maybe someone knows has a link with an example.
Have a look at codemodel, used with success for my projects.