Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » problem with nested elements and wrappers
problem with nested elements and wrappers [message #508009] Fri, 15 January 2010 09:44
Eclipse UserFriend
Originally posted by: murbieta.gpi.com.ar

Hi i'm facing a problem when trying to specify a gmf solution for a
xsd-derivated emf model. This model generates wrappers for collections
that prevents setting the right containment feature ( the wrapper object
is resolved instead ) in a top mode reference (gmfmap file). The
wrappers are generated due to the xml is full of complextypes.
I was thinking about make a "lite" version of the model for working and
transform it to/from the complex version when saving/loading.

Next, i'll present the case:

My xsd specifies the following schema :

<xs:element name="step">
<xs:complexType>
<xs:sequence>
<xs:element ref="external-permissions" minOccurs="0" />
<xs:element ref="actions" minOccurs="0" />
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required" />
<xs:attribute name="id" type="xs:string" use="required" />
</xs:complexType>
</xs:element>

<xs:element name="steps">
<xs:complexType>
<xs:sequence>
<xs:element ref="step" maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
</xs:element>

<xs:element name="workflow">
<xs:complexType>
<xs:sequence>
..
<xs:element ref="steps" />
...
</xs:sequence>
</xs:complexType>
</xs:element>

This schema allows specifying an xml like

<workflow>
<steps>
<step id=.../>
....
</steps>
</workflow>

When i derivate this schema to EMF, three Eclasses are created
WorkflowType, StepsType and StepType. The first have a reference to a
StepsType instance and this last has a list to StepType instances.Here,
the StepsType works as a decorator for the stepType list.

In my GMFmap specification, i set the WorkflowType as canvas' domain
meta element. when trying to set the StepType container feature at a
top node reference, it is not available due to it is provided by
StepsType which actually is available.

How can i set indirections in containment feature of top node
reference ?

regards
Previous Topic:GMF Ecore Model Problem
Next Topic:connection and node
Goto Forum:
  


Current Time: Fri Apr 19 01:45:26 GMT 2024

Powered by FUDForum. Page generated in 0.01862 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top