NEW! MAGICDRAW UML 17.0.1 FILE FORMAT CHANGES
File Formats in MagicDraw 17.0.1
3 0
Copyright © 2003-2011 No Magic, Inc..
Version 17.0.1 saves the diagram element as a separate element extension named <modelExtension>. This
extension is stored in place where the diagram element is serialized (inside a diagram owner). If one owner has
more than one diagram, they may be written in the one extension. In this extension, a diagram element is saved
as a normal model element, and all its attributes and references are saved according xmi rules. A diagram
element contains DiagramRepresentationObject, which contains information about a diagram type, required
features, and so on. DiagramRepresentationObject contains DiagramContentsDescriptor, which describes
used elements in diagram and contains BinaryObject. BinaryObject has the attribute “streamContentID” which
identifies a zip entry for diagram symbols. All information is stored in <mdOwnedViews>. The following schema
presents finding diagram symbols entry id:
Diagram > DiagramRepresentationObject > DiagramContentsDescriptor > BinaryObject > BinaryObject.
streamContentID
Genmodel for DiagramRepresentationObject and DiagramContentsDescriptor
<?xml version="1.0" encoding="UTF-8"?>
<genmodel:GenModel xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI" xmlns:ecore="http://www.eclipse.org/emf/
2 0 0 2 / E c o r e "
xmlns:genmodel="http://www.eclipse.org/emf/2002/GenModel" modelDirectory="/
c o m . n o m a g i c . m a g i c d r a w . f o u n d a t i o n / s r c "
modelPluginID="com.nomagic.magicdraw.foundation" modelName="Diagram"
u p d a t e C l a s s p a t h = " f a l s e "
rootExtendsInterface="org.eclipse.emf.cdo.CDOObject"
rootExtendsClass="org.eclipse.emf.internal.cdo.CDOObjectImpl"
reflectiveDelegation="true" importerID="org.eclipse.emf.importer.ecore"
f e a t u r e D e l e g a t i o n = " R e f l e c t i v e "
containmentProxies="true" complianceLevel="5.0" copyrightFields="false"
usedGenPackages="../../com.nomagic.ci.metamodel.project/model/binary.genmodel#//
binary"
classNamePattern="">
<foreignModel>diagram.ecore</foreignModel>
<modelPluginVariables>CDO=org.eclipse.emf.cdo</modelPluginVariables>
<genPackages prefix="Diagram" basePackage="com.nomagic.magicdraw.foundation"
d i s p o s a b l e P r o v i d e r F a c t o r y = " t r u e "
ecorePackage="diagram.ecore#/">
<genClasses image="false" ecoreClass="diagram.ecore#//
AbstractDiagramRepresentationObject">
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/ID"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/type"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/umlType"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/diagramProperties"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/initialFrameSizeSet"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/requiredFeature"/>
<genFeatures property="None" children="true" createChild="true"
ecoreFeature="ecore:EReference diagram.ecore#//
AbstractDiagramRepresentationObject/diagramContents"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//AbstractDiagramRepresentationObject/diagramStyleID"/>
</genClasses>
<genClasses ecoreClass="diagram.ecore#//DiagramContentsDescriptor">
<genFeatures property="None" notify="false" createChild="false"
ecoreFeature="ecore:EReference diagram.ecore#//DiagramContentsDescriptor/
representation"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//DiagramContentsDescriptor/exporterName"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute
diagram.ecore#//DiagramContentsDescriptor/exporterVersion"/>