Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[gmf-dev] problem with xsd derivated model and containment features

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.
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 cambas' 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
  




Back to the top