Re: Unordered content model in XSDL

Ian Stokes-Rees writes:

>> I cannot seem to work out how you would 
>> create a schema that allowed any
>> number of elements A, B, C, or D inside 
>> an element sample.  e.g.:

>> <sample>
>>   <C/>
>>   <A/>
>>   <A/>
>>   <C/>
>>   <C/>
>>   <B/>
>> </sample>

The pertinent content model fragment is (using local elements):

        <choice minOccurs="0" maxOccurs="unbounded">
                <element name="A" type="...."/>
                <element name="B" type="...."/>
                <element name="C" type="...."/>
        </choice>

or with globals:

        <choice minOccurs="0" maxOccurs="unbounded">
                <element ref="A" />
                <element ref="B" />
                <element ref="C" />
        </choice>

Note that the above is directly (and intentionally) analagous to the 
common DTD construction:

        (A | B | C)*

Hope this helps.

------------------------------------------------------------------------
Noah Mendelsohn                                    Voice: 1-617-693-4036
Lotus Development Corp.                            Fax: 1-617-693-8676
One Rogers Street
Cambridge, MA 02142
------------------------------------------------------------------------

Received on Friday, 12 January 2001 12:12:55 UTC