Page 1 of 1

customization of code generation in MagicDraw?

PostPosted: Fri Nov 29, 2002 11:56 am
by Jan Geiger

I have a few questions regarding the code generation facility in MagicDraw.
We're evaluating Magic Draw for usage in a software project using an MDA

The model shall be UML diagrams (foremost class diagrams) and we want to
put all important information into these diagrams using extension mechanisms
stereotypes and tagged values. An example would be a class "Customer" in the
having the stereotype <<BusinessObject>> and some attributes like
OID, customerID, name, address and all that stuff. Some of the fields of
such a class
should be marked as persistent or transient for example or be denominated as
object identifier, etc.

Then we want to generate code (OR mapping descriptors and of course Java
Interfaces and classes)
from the UML model considering all the stereotypes and tagged values.

a) Is this possible in Magic Draw?

b) Can the process of code generation be customized to meet our
requirements, e.g. using a template language like Apache Velocity?

In the accompanying documentation I didn't find a hint to a possibility for
such customizations.

Thanx for your help,

Jan Geiger

Re: customization of code generation in MagicDraw?

PostPosted: Fri Jul 12, 2013 3:14 pm
I have the same question, and for the same reasons. How extensible is the code generation and reversing?


Bryan Pugh

Re: customization of code generation in MagicDraw?

PostPosted: Mon Jul 15, 2013 4:16 am
by saulius_p

You are right MagicDraw Velocity template based report engine can be used for custom code generation. VTL is used for Oracle DDL generation and for custom - extended XML Schemas generation purposes. Report Wizard can be used to generate custom any types of files based on VTL templates.

You can find more at: Reports Generation section