Skip to main content



      Home
Home » Modeling » EMF » XINCLUDE support
XINCLUDE support [message #413522] Wed, 03 October 2007 07:15 Go to next message
Eclipse UserFriend
hello,

I have a set of documents which are related to from one to another.

corporation.xml
<organization>
<person> ... </person>

<xi:include href="branch.xml#/"/>

<person> ... </person>

<xi:include href="branch2.xml#/"/>
<xi:include href="branch3.xml#/"/>


</organization>


branch.xml
<organization>
<person> ... </person>
</organization>



branch1.xml
<organization>
<person> ... </person>
</organization>



So in object model Organization can contain other sub-organizations (in List
of organizations)


How to model this relationships in EMF.ECORE mode?
How to say that reference will be created in another .xml file and this
reference will be represented by <xi:include href="" tag?

Thank You for any help,
John Cage
Re: XINCLUDE support [message #413530 is a reply to message #413522] Wed, 03 October 2007 08:24 Go to previous message
Eclipse UserFriend
John,

Unfortunately we have no support for xi:include. You can make your
SAXParser include aware so that you can read such an instance, but I've
never experimented with that. The resulting SAX stream I assume would
make it look like it all came from a single file so it would be written
out to a single file in the end.

EMF itself does support containment proxies that work much like
xi:include. Any containment EReference for which resolveProxies is true
and is generated with the GenModel's Containment Proxies property set to
true, will allow you to place the contained child in a different
resource so you'd get something like

<organization href="branch.xml#/"/>

as the serialization of an organization that's contained in a different
resource.


eclipsemaniac wrote:
> hello,
>
> I have a set of documents which are related to from one to another.
>
> corporation.xml
> <organization>
> <person> ... </person>
>
> <xi:include href="branch.xml#/"/>
>
> <person> ... </person>
>
> <xi:include href="branch2.xml#/"/>
> <xi:include href="branch3.xml#/"/>
>
>
> </organization>
>
>
> branch.xml
> <organization>
> <person> ... </person>
> </organization>
>
>
>
> branch1.xml
> <organization>
> <person> ... </person>
> </organization>
>
>
>
> So in object model Organization can contain other sub-organizations (in List
> of organizations)
>
>
> How to model this relationships in EMF.ECORE mode?
> How to say that reference will be created in another .xml file and this
> reference will be represented by <xi:include href="" tag?
>
> Thank You for any help,
> John Cage
>
>
>
>
>
Previous Topic:MappingEditor enhancement request ?
Next Topic:XSD to Ecore Generation
Goto Forum:
  


Current Time: Sun Jul 27 14:06:44 EDT 2025

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

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

Back to the top