Getting the Best out of an MDG

By Phil Chudley Principle Consultant and Sparx EA Expert

The use of MDGs is widespread in EA and many companies develop their own MDGs to model their Metamodel. In this talk, Phil will share his experience of developing many such MDGs over the years.
Highlights of this session include:
  • The best approach when designing and developing an MDG
  • Should an existing Metamodel be extended or is it better to start from scratch?
  • Common traps / pitfalls and how to avoid them
  • Tricks with Shapescripts
  • Implementing Quicklink rules using Stereotype relationships and meta-constraints
  • Filtering a MetaModel using View Specifications

Session Recording


EA Global Summit - Getting the Best Out of an MDG (PPTX)
Metamodel Demo MDG (ZIP)

Learn More

Questions and Answers

There's no simple solution if the quicklink rules change between versions. The solution we came up with was to write a validation / update script to identify and apply the changes.
Quick answer that this is documented in the Resource books on the Sparx website. The book is called MDG Technologies. I will post a more detailed reply when I have had a chance to implement it myself. But briefly, you have to create an XMI file for the import of a structure that the wizard will create and a RTF document for the text guide. Then you have to modify the MTS file manually to add a section (I think it’s called < models>< /models>) which contain the absolute path to these files
Do you mean the Metatype in the Properties for the Profile Helper? If so, this entry is type that EA uses as the Type (as in the element properties), it is also used for the name of a new element when added to the diagram. However, metaclass is still the underlying type as in t_object table or in the Type field when exported / import to / from CSV.
EAPX is the newer JET engine database drivers (used for access databases). Have a look on the Start Ribbon, under Preferences- you can enable the JET 4.0 drivers and allow EAPX files. Otherwise, you are using the older EAP files (which is JET 3.5).
In my understanding, a Wizard only adds new elements, however in an MDG a diagram using stereotypes and relationships can be saved as a Pattern, which can create new elements and also apply a pattern to existing elements of the same stereotype
I do intend to do this hopefully within this week, I have uploaded a Script to automate the process of saving profiles and generating the MDG. It is ins the Downloads section. I have uploaded the javascript source and it assumes that a manual generation has been completed, So, you can use this for successive generations. This script will not update the Version number of the MDG, so if you wish to update the version simple do a manual generation

Speaker Bio


Phil Chudley

Principle Consultant and Sparx EA Expert