[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: canonicalization

define canonicalization
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@m... | 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/    |


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.

Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.