![]() |
XML Schema <-> DTD ? equivalent to external ENTITY
Hi,
I woult like to switch from DTD to XML-Schema and am looking for an equivalent to external ENTITY for composition of an xml file from modules --- my.dtd -- <?xml version="1.0" encoding="ISO-8859-1"?> <!ENTITY module1 SYSTEM "module1.xml"> <!ENTITY module2 SYSTEM "module2.xml"> ..... --- my.xml --- ( + module1.xml, module2.xml ) <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE my SYSTEM "my.dtd"> <my> &module1; &module2; </my> .... modul1.xml and modul2.xml are included in my.xml and validated with my.dtd together. how could I realize this with XML Schema ? thanks in advance Robert P.S.: the modules should be validated together because of common ID/IDREF scope I know XML Schema can be composed of multiple files with <include> and <import> but xml data ? |
Re: XML Schema <-> DTD ? equivalent to external ENTITY
include and import.
Bob "Robert Lintner" <rlintner@etm.at> wrote in message news:1058534664.685482@newsmaster-03.atnet.at... > Hi, > > I woult like to switch from DTD to XML-Schema and am looking for an equivalent > to external ENTITY for composition of an xml file from modules > > --- my.dtd -- > <?xml version="1.0" encoding="ISO-8859-1"?> > <!ENTITY module1 SYSTEM "module1.xml"> > <!ENTITY module2 SYSTEM "module2.xml"> > .... > > --- my.xml --- ( + module1.xml, module2.xml ) > <?xml version="1.0" encoding="ISO-8859-1"?> > <!DOCTYPE my SYSTEM "my.dtd"> > <my> > &module1; > &module2; > </my> > > ... modul1.xml and modul2.xml are included in my.xml and validated with my.dtd > together. > > how could I realize this with XML Schema ? > > thanks in advance > > Robert > > P.S.: the modules should be validated together because of common ID/IDREF scope > I know XML Schema can be composed of multiple files with <include> and <import> > but xml data ? > > > |
Re: XML Schema <-> DTD ? equivalent to external ENTITY
In article <bfcisb$1sv2$1@pc-news.cogsci.ed.ac.uk>,
richard@cogsci.ed.ac.uk says... > The most straightforward solution is to continue using entities. You > can use a DTD for entities and a schema for validation. Interestingly it appears to be impossible to get Xerces-J v2.4.0 (at least) to validate such an arrangement. In particular, if one turns on schema validation, then DTD validation is also turned on. Since the DTD does not declare the elements (if it only provides entities), the result is a large stream of validation errors about undeclared elements coming from the DTD validator. The Xerces documentation talks about this issue and basically says there is currently no resolution. That seems hard to believe. Does anyone here know anything to the contrary? Peter |
Re: XML Schema <-> DTD ? equivalent to external ENTITY
richard@cogsci.ed.ac.uk (Richard Tobin) writes:
> In article <NrgSa.86034$GL4.22868@rwcrnsc53>, > Bob Foster <bobkfoster@comcast.net> wrote: > > >include and import. > > No, those are for composition of schemas, not documents. They correspond > very roughly to parameter entities rather than general entities. > how about http://www.w3.org/TR/xinclude/ ? Susanne |
| All times are GMT. The time now is 08:44 PM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.