Add a SubElement to an new created Element [message #501134] |
Tue, 01 December 2009 03:55 |
Eclipse User |
|
|
|
Hi,
i have a problem. I have to create a new Element (Rectangle, with something).
After creating this, it have to instantly connect to an other element. I have some problems in doing this.
My Mapping:
<nodes>
<containmentFeature
href="model.ecore#//Diagram/Lines"/>
<ownedChild>
<domainMetaElement
href="model.ecore#//Dot"/>
<domainInitializer
xsi:type="gmfmap:FeatureSeqInitializer">
<initializers
xsi:type="gmfmap:ReferenceNewElementSpec">
<feature
xsi:type="ecore:EReference"
href="model.ecore#//Dot/sourceConnections"/>
</initializers>
<initializers
xsi:type="gmfmap:FeatureValueSpec">
<feature
xsi:type="ecore:EReference"
href="model.ecore#//Dot/sourceConnections"/>
<value/>
</initializers>
</domainInitializer>
<tool
xsi:type="gmftool:CreationTool"
href="model.gmftool#//@palette/@tools.0/@tools.0"/>
<diagramNode
href="model.gmfgraph#Dot"/>
<children
referencedChild="//@nodes.0/@ownedChild">
<containmentFeature
href="model.ecore#//Diagram/Lines"/>
<childrenFeature
href="model.ecore#//Dot/target"/>
</children>
</ownedChild>
</nodes>
i am not a guru and i know this mapping is totally wrong, but i think its the right way to solve this.
Thanks
Thomas
|
|
|
Powered by
FUDForum. Page generated in 0.04418 seconds