Is document order of content in XML required?

I've had an interesting discussion occur within my organization. I have 
some folks that are advocating for a sequence attribute on a repeating 
element situation.

I have the following design:

<!ELEMENT Group (Content | Group)+>

They want the Group and Content element to have a sequence number/attribute 
because they believe implied order (order in the document instance) is not 
required to be maintained. This may have started with the early DOM 
implementations from some of the arguments that I'm getting.

Comments?

I don't believe this is true and I'll explain below, but they want a 
reference in the schema or XML spec that says - document order is preserved 
and important. I have a feeling that it isn't there because this is such a 
fundamental requirement that it is like stating the obvious - "the sky is 
blue". Because I can't come up with a reference they won't believe my 
following reasoning:

1) How do all those publications/documents work like HTML where there is a 
repeating <p> tag ? No one numbers these elements.

2) I have stylesheets that have been working against the above design and 
they have never lost order from the source document.

3) XPath/XSLT talk about document order, you have the position() function, 
you have the position parameter p[1] and axis specifiers that read in 
document or reveres document order

4) The Schema spec itself uses this design for specifying the content of an 
element or complex data type.

please help

..dan
---------------------------------------------------------------------------
Danny Vint
http://www.dvint.com


     

Received on Tuesday, 28 October 2003 13:14:50 UTC