W3C home > Mailing lists > Public > xmlschema-dev@w3.org > June 2009

[XML Schema 1.1] <openContent> applies only to the children, not the grandchildren ... correct?

From: Costello, Roger L. <costello@mitre.org>
Date: Wed, 3 Jun 2009 14:41:48 -0400
To: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>
Message-ID: <9E51F88D5247B648908850C35A3BBB5003FD6BE6FF@IMCMBX3.MITRE.ORG>

Hi Folks,

I want to confirm my understanding.

Consider this <Book> element with open content:

<element name="Book">
        <openContent mode="interleaved">
            <any />
            <element name="Title" type="string"/>
            <element name="Author">
                        <element name="FirstName" type="string"/>
                        <element name="LastName" type="string"/>
            <element name="Date" type="string"/>
            <element name="ISBN" type="string"/>
            <element name="Publisher" type="string"/>

Notice that the <Author> element has child elements, which are grandchildren of the <Book> element.

Extension elements can only be added before and after the *children* of Book. Extension elements cannot be added around the *grandchildren* of Book. Thus, extension elements cannot be added before or after <FirstName> and <LastName>.

Is this correct?

Received on Wednesday, 3 June 2009 18:42:23 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:15:51 UTC