Prev | Next |
Incorporate Model Templates
When a user creates a model within their project, they can choose the type of model to develop from a range of system-supplied model templates presented through the Model Wizard. You can also develop custom model templates and add them to this list via your MDG Technology.
Access
You edit the .MTS file directly, using whatever file browser you work with to locate and open the file.
Add custom model templates to MDG Technology
Step |
Action |
See also |
---|---|---|
1 |
Create a Package that contains all sub-Packages, diagrams, elements, notes and information links that you want to provide in your model template. See the EAExample.eap model for illustrations of what you might include, or create a model from a standard template and see what is generated. As a model template, the Package would be self contained and not contain any dependencies or other links to elements outside the Package. |
Model Wizard |
2 |
Export your Package to XMI. |
Export to XMI |
3 |
Create a reference to the XMI file in the MTS file; open your MTS file in a text editor and copy and paste this <ModelTemplates> block at the top level inside the <MDG.Selections> block:
<ModelTemplates> <Model name="Template Name" location="MyTemplatePackage.xml" default="yes" icon = "34" isFramework="false"/> </ModelTemplates>
You can include as many <ModelTemplates> blocks in your MTS file as you have model templates. The attributes within a <ModelTemplates> block have these meanings:
|
Working with MTS Files |
4 |
Regenerate the MDG Technology using the edited MTS file. |
|
5 |
To allow multiple custom categories per technology, go to the <Documentation> row of the MDG Technology file and add the attributes:
In the <ModelTemplates> block of the MDG Technology file, each <Model> row will have an attribute groupName. The group name must be in categoryMappings. |
Learn more