MetaCase Homepage
Forum Home Forum Home > > MetaEdit+
  New Posts New Posts RSS Feed - Export metamodel in xml
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Export metamodel in xml

 Post Reply Post Reply
Author
Message
maximus View Drop Down
Member
Member


Joined: 29.Apr.2008
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote maximus Quote  Post ReplyReply Direct Link To This Post Topic: Export metamodel in xml
    Posted: 20.May.2008 at 12:01
Hej,

I want to export (to make an import later on) in xml of my metamodel. I tried to do this at the type manager, where all types where selected and then I select 'export to xml'. Unfortunately, not all my types are exported to xml.

To explain my situation a little bit easier, the situation occurs also in the BPMN example (I do a similar concept as in BPMN: In BPMN, you can create an 'intermediate' (yellow circle). By specifying the trigger, you get an Icon in your yellow circle. The objects you can choose as an trigger are some special objects and based on that, the icon is showed.

If I export the metamodel (in the type manager) to xml, I don't see those subobjects back in the xml (Cancel, Compensation, Error, Link, ...). Why is this, and how can I manage to get them in xml.

The thing is, I want to use the xml as an import. Before the import, there will be (well: that's the idea) an xsl-transformation to add special types. So in the BPMN example: I would like to specify all the triggers (the subtypes and the icons) in xml, because in my case the list of available triggers is changing all the time (so by extracting them from a database, and mix it in xml with the metamodel definition, I hope to get an 'dynamic metamodel' which allways supports my 'triggers' without always redefine the modelling language in MetaEdit+)

Hopefully my problem is clear, and there is a solution available,
Greets,
Max
Back to Top
stevek View Drop Down
MetaCase
MetaCase
Avatar

Joined: 11.Mar.2008
Points: 643
Post Options Post Options   Thanks (0) Thanks(0)   Quote stevek Quote  Post ReplyReply Direct Link To This Post Posted: 20.May.2008 at 15:03
Hej Max!
 
XML isn't very smart in this case: since the subtypes aren't mentioned anywhere in the metamodel, e.g. as types in a Graph type or as the data type of a Property type, they don't appear in the MXT file. The binary .MET file includes them correctly, but that's not editable.
 
The easiest solution is to create a new Graph type, "_Subtypes", and add all the types in the Trigger type hierarchies (and maybe the other hierarchies like _AdHoc, _Result, _Task type). If you export BPMN and _Subtypes together, you'll get all the types you need. You can then simply insert any extra types you want into the _Subtypes graph type's list of <object> types, and re-import that. If you want to hide that _Subtypes graph type from the modeler, you can use "Remove type" in the Type Browser pop-up menu after importing. Use "Salvage types" in the same menu if you want to make it visible again for export etc.
 
When adding your own subtypes to the MXT, remember to give them unique id and type attributes, "Object_<nameWithUnderlinesForSpaces>_user_<10digits>". If you create duplicate types to allow the same type to be used in multiple properties (e.g. one as a subtype of _Trigger (intermediate) and another as a subtype of _Trigger (start)), remember to give each type its own id and type attributes.
Back to Top
maximus View Drop Down
Member
Member


Joined: 29.Apr.2008
Points: 6
Post Options Post Options   Thanks (0) Thanks(0)   Quote maximus Quote  Post ReplyReply Direct Link To This Post Posted: 20.May.2008 at 16:35
Thanks! It looks like it works Thumbs%20Up
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.05
Copyright ©2001-2022 Web Wiz Ltd.

This page was generated in 0.047 seconds.