A code generator needs input. Hence some "generic formal language" is used to specify the input to the genric code generator? UML? Visualization of a generic language could mean - speak UML, UML is a reality today. UML modells can says much more then 1000 words? Hence I opt for better integration of modelling tools with maven. Also roundtrip engineering is a must. Enterprise Architect (EA) is able to generate code from UML and other diagrams for many target compiler and it helps you to have code, modell and documentation in sync. And EA can be feed with code and generates your diagramms. A task which only ends when the modells become to complex. Maven is much about geting and nailing dependent components together. If maven finds the dependecies, a tool like EA could use input to draw i.e. the component diagram, maybe a maven plugin can pave the way for EA. Other whise, in my mind, there are far too many tools around and I get to often the feeling that each time a problem developes, folk starts to seek a tool to avoid some brain work. So if one knows in which aspects maven poms could be used toward EA to get ceratin artiacs visualized for better understanding, that would be almost a very good step into proper direction. Josef
-----Ursprüngliche Nachricht----- Von: [email protected] [mailto:[email protected]] Gesendet: Mittwoch, 27. Februar 2013 12:31 An: [email protected] Betreff: Is there any generic Maven code generator? I just posted this to Stackoverflow, but after posting I realized, that I should have come here first :-( I am currently working on a project, that makes intense usage of code generation for various purposes. One generator generates SQL scripts from jpa entities. Another generates DTOs from pojos, another generates the JPA2.0 meta model, jet another generates some xml and schema files based on Java classes ... each generator works completely different needs to be configured differently. My question now is ... is there any generic maven code generator plugin out there with the following attributes: * Creates a pojo model of a Java class (Names, Properties, Annotation, Methods ...) * Uses templates for defining the output that uses the pojo model to generate any output. * Allows me to specify multiple templates for one class * Allows me to generate code and resources * Allows me to generate a base class to target/generated-sources and a dummy implementation to src/main/java which simply extends the base class (If the dummy class in src/main/java exists, nothing happens, if it doesn't it generates such a dummy class. This code is checked in to the SCM and allows extending the generated classes manually) I am using the Flexmojos GraniteDS plugin for generating my ActionScript model code, but it's pretty specialized for that particular purpose. I think such a generic generator would make things a lot easier ... is there something like that available out there, or do I have to start implementing it myself? Chris --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
