Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Representing multiple domain models in one visual representation
Representing multiple domain models in one visual representation [message #122412] Fri, 27 April 2007 16:54 Go to next message
Eclipse UserFriend
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!
Re: Representing multiple domain models in one visual representation [message #122528 is a reply to message #122412] Mon, 30 April 2007 08:41 Go to previous message
Eclipse UserFriend
Hello Renee,

Try using IPaletteProvider to manually create this kind of wntries + put
them onto palette.

-----------------
Alex Shatalin
Previous Topic:Inconsistency of links in compartments
Next Topic:Runtime Pluggin
Goto Forum:
  


Current Time: Wed Jul 23 08:15:56 EDT 2025

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

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

Back to the top