- This topic has 3 replies, 2 voices, and was last updated 15 years, 11 months ago by Riyad Kalla.
-
AuthorPosts
-
Development LicenseMemberHi there
I scanned through the forums but couldn’t find anything recent so excuse me if this has been answered already. There seems to be a few requests (3 – 4 years old) for the ability to generate your own code from the UML diagrams. I specifically want to be able to generate Java and maybe other code from the UML diagram but would need to be able to access the tagged values to generate extra code.
I am currently doing this with Enterprise Architect, saving it as XMI and then running my own code to generate Hibernate, SQL, POJO’s and other files using velocity. But to explain to new people how XMI works (specifically because we do fancy things based on special tags) is a problem and I want to simplify this. I am hoping you guys can tell me that we can access the UML model in some OO way… ?
Regards
Marius
Riyad KallaMemberMarius,
Actually in our UML1 tool we have had Java forward-and-reverse engineering in for quite a while and recently added XSD generation in the 6.6 release and beyond.
Our UML2-based modeling tools are currently in “Early Access” stages and have a lot more work planned for them including forward-and-reverse engineering just like UML1, as well as adding XSD generation and also importing of RSA and XMI files.
The UML2-based modeling will be more closely suited to what you are looking for because it is based on the Eclipse UML2 project and works with very standard files and formats that are extremely tool-able. The UML1 tool can also be easily tooled, it’s just a different animal. The “UMR” file it creates is actually a ZIP file of all the sub-files used to store the model and graph information if you wanted to dig into it.
Development LicenseMemberThanks, I will download the latest version and try that. Can you just confirm that :
1. ALL information in the model will be exported to XSD, including the custom tags / tagged values that may not be standard. I.e. I may choose not to use the forward-and-reverse engineering you have and write something myself.
2. Is it possible to find or look at the templated you use to generate the Java code. I would be interested to know if we may add to it. That will save me a lot of time.Thanks
Marius
Riyad KallaMember1. I *think* this is the case… I haven’t worked too heavily with custom tags and the XSD generation, but I believe that is true.
2. For the source code you’d have to email info@genuitec.com and ask them (please describe your situation and use case), feel free to dig through the com.genuitec.eclipse.uml_7.0.0.zmyeclipse70020081206.jar plugin for anything interesting — I’m not entirely sure what’s all in there with regards to templates though.
-
AuthorPosts