[
Lists Home |
Date Index |
Thread Index
]
Hi Alessandro,
Henry Thompson wrote:
>> The chances ought to be high if the <all> group is being used
>> responsibly (which it often isn't, in my experience). Let's
>> approach this from the other side -- if an element is declared to
>> contain a, then b, then c as children, then the relative order of
>> a, b and c in an instance carries no semantics. From this Occam
>> suggests that in cases where there is no intention to convey
>> different semantics with different order among siblings, a sequence
>> should always be used, to avoid potential misunderstanding. _If_
>> this argument is persuasive, then you should _only_ use <all> when
>> order _does_ matter, in which case re-arrangement changes the
>> meaning of the document and should be avoided.
[snip]
> I would like to hear other people's views as well.
I agree with Henry. To give an example, in RELAX NG, a common use for
<interleave> is for mixed content. If you imagine:
<p>
A paragraph with <em>emphasised</em> text.
</p>
with the simple schema:
element p { text & em* }
it would be very wrong to move the <em> element to the start of the
paragraph -- it would change the meaning of the document.
There's a distinction between whether the order of elements is
*constrained* and whether their order is *significant*. all and
interleave simply indicate that the order is unconstrained, they say
nothing about whether the order is significant. Unfortunately we use
"matters" when talking about both of these.
See also Tommie Usdin's paper from Extreme last year:
http://www.idealliance.org/papers/extreme02/html/2002/Usdin01/EML2002Usdin01.html
which is a great read on precisely this topic.
Cheers,
Jeni
---
Jeni Tennison
http://www.jenitennison.com/
|