OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   Re: [xml-dev] canonicalization

[ Lists Home | Date Index | Thread Index ]

At 12:12 PM -0500 3/4/02, Simon St.Laurent wrote:

>It is both an element and a "syntax for general purpose inclusion....
>merging a number of XML information sets into a single composite
>XInclude explicitly avoids definining relationships with XML Schemas and
>DTDs, but this kind of non-definition feels eerily to me like Namespaces
>in XML, which is concise but has left us debating for the last few

The algorithm for DTD validation is defined by XML 1.0. XInclude 
doesn't change it. Give me an XML document and a validating parser, 
and I can tell you whether or not that document is valid. The 
presence or absence of XInclude elements is irrelevant to this 
determination. If they're present, the DTD just has to declare them 
like any other elements in order for them to be valid. Schemas are 
similar, except it's even easier because you don't necessarily have 
to serialize the infoset before applying the validation algorithm.

Canonicalization is similar, except the algorithm is even more 
clearly defined. Give me an XML document. I'll apply the algorithm to 
it and return its canonical form. This algorithm assigns no special 
semantics to any elements including xinclude:include elements. 
XInclude does not change the definition of canonicalization.

Most importantly, XInclude does not change the definition of an XML 
document. A process such as canonicalization which is designed to 
operate on arbitrary XML documents does not change its behavior when 
the document happens to contain xinclude:include elements.

>  Documents may now be read as describing multiple infosets - one
>including XInclude elements as elements, one representing the result of
>complete infoset merging, and various infosets representing possible
>failure states.

No, that's the confusion. A single XML document describes a single 
infoset. A single document does not describe multiple infosets. 
Performing inclusion on a document generates a new infoset, which if 
you choose can be serialized into a new document. (Actually there are 
a few holes in the spec here, but they're not relevant to the current 
discussion.) This is not, however, the infoset that was described by 
any of the original documents (again, except in the trivially 
uninteresting case where the original document did not contain any 
xinclude:include elements).

Documents may not be read as describing multiple infosets, at least 
not if you wish to be conformant to the various W3C specs. You can 
use XInclusion to produce new infosets from old infosets, but then 
you can do this with XSLT, SAX, or DOM, so this is nothing new.


| Elliotte Rusty Harold | elharo@metalab.unc.edu | Writer/Programmer |
|          The XML Bible, 2nd Edition (Hungry Minds, 2001)           |
|             http://www.cafeconleche.org/books/bible2/              |
|   http://www.amazon.com/exec/obidos/ISBN=0764547607/cafeaulaitA/   |
|  Read Cafe au Lait for Java News:  http://www.cafeaulait.org/      |
|  Read Cafe con Leche for XML News: http://www.cafeconleche.org/    |


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS