W3C home > Mailing lists > Public > xmlschema-dev@w3.org > July 2000

XML Schema: element ordering

From: Robin LaFontaine <robin@monsell.co.uk>
Date: Wed, 12 Jul 2000 15:17:48 +0100
Message-Id: <v04210123b5922d0ad4ef@[]>
To: xmlschema-dev@w3.org
There is a basic requirement for most data structures to distinguish 
between a 'list', which is ordered, and a 'set' which is not.

I cannot see how, in XML Schema, to make this distinction.

For example:

    <element name="CoordGeom">
              <choice minOccurs="0" maxOccurs="unbounded">
                  <element ref="Line"/>
                  <element ref="Curve"/>
                  <element ref="Spiral"/>

How can I indicate if the sequence of element instances within the 
choice is significant ('list') or not ('set')?

I have not been able to determine the answer to this question from 
reading the spec, except that by omission I think the answer is 'you 
cannot do this in XML Schema'! That would be a serious limitation for 
data structures.

Any help appreciated.

-- -----------------------------------------------------------------
Robin La Fontaine, Monsell EDM Ltd
(R&D Project Management, Engineering Data Exchange using XML, EDIF)
Tel: +44 1684 592 144 Fax: +44 1684 594 504 or +44 870 054 2811
Email: robin@monsell.co.uk       http://www.monsell.co.uk
Received on Wednesday, 12 July 2000 10:26:16 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:14:46 UTC