Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: XML Schema: inheritance with variable order of childs

From: usenet@--------------.---
To: NULL
Date: 11/5/2007 5:51:00 AM

On 5 Nov, 11:20, Sven <s...@ast.dfs.de> wrote:
> What is the intention of xs:all? Is it just the same like xs:sequence
> with having no strict order? But in xs:all all elements have to be
> present exactly one time, right? There is no possibility to define
> optional or multiple elements?!
>

xs:all is similar to xs:sequence, but, as you say, does not impose a
strict order.  Elements from an xs:all in an XML instance can occur 0
or 1 times, but _not_ 2 or more.  Unlike like xs:sequence, xs:all does
not allow anonymous compositors, can't be used as an anonymous
compositor, and can't extend from a base or be extended.

> By the way, why is s sequence the main collection type? I can see no
> reason for a strict order of the child elements anyway.

The restrictions on xs:all were imposed because at the time it was
thought that the impact on a finite state machine implementing
validation would suffer combinatorial explosion type problems.  I
imagine that xs:sequence is ordered for similar reasons.  (Note that
it's now considered that there are better ways to validate xs:all than
implementing a finite state machine and future versions of schema are
likely to allow more relaxed forms of xs:all.)

HTH,

Pete Cordell
Codalogic
Visit http://www.codalogic.com/lmx/
for XML Schema to C++ data binding



transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent