Representing multiple domain models in one visual representation [message #122412] |
Fri, 27 April 2007 16:54  |
Eclipse User |
|
|
|
Originally posted by: renee.steiner.intervoice.com
I have two simple schemas.
The first schema defines a child element as xs:any
The second schema defines an element I wish to insert into the first
element at tooling runtime to build a document.
--------------first schema--------------------------
<?xml version="1.0" encoding="ISO-8859-1"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified">
<xs:element name="persons">
<xs:complexType>
<xs:sequence>
<xs:element ref="person"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="person">
<xs:complexType>
<xs:sequence>
<xs:element name="firstname" type="xs:string"/>
<xs:element name="lastname" type="xs:string"/>
<xs:any minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
--------------second schema--------------------------
<?xml version="1.0" encoding="ISO-8859-1"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://www.children.com"
xmlns="http://www.children.com" elementFormDefault="qualified">
<xs:include
schemaLocation="../../com.intervoice.familymodel/model/family.xsd "></xs:include>
<xs:element name="children">
<xs:complexType>
<xs:sequence>
<xs:element name="childname" type="xs:string"
maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
The problem I am having is combining the two models created by the XSD
imports into a single .gmfmap.
I need to define a palette that hold creation tools from both schemas.
I also need to define a .gmfmap which allows the first schemas to accept a
child element from the second schema.
The most benefical solution would be to create a second tool palette and
gmfgraph defintion that could be part of the first model definition and
allow any type of element to be inserted in the <xs:any> slot. In other
words, we want one palette to hold all creation tools even if they are
defined in a separate emf project.
I appreciate all comments and help that can be given. Thanks!
|
|
|
|
Powered by
FUDForum. Page generated in 0.03506 seconds