W3C home > Mailing lists > Public > xmlschema-dev@w3.org > May 2001

Extnsions for extended complexTypes

From: Michael Shapiro <michael@creativescience.com>
Date: Wed, 30 May 2001 12:17:49 -0700
Message-ID: <008301c0e93d$37158d10$110a0a0a@voquetter>
To: <xmlschema-dev@w3.org>
I have some problems with understanding "3.4.6 Constraints on Complex Type Definition Schema Component"[1].
My reading is that if the complexType "A1" is an extension of complexType "A0" then complexType "A2" cannot be
an extension of complexType "A1" - only restricted complex type would be valid.

Is it correct interpretation?

Invalid schema:

    <complexType name="A0">
            <element name="a0" type="string"/>
    <complexType name="A1">
        <extension base="A0">
                <element name="a1" type="string"/>
    <complexType name="A2">
        <extension base="A1">
                <element name="a2" type="string"/>
    <element name="test" type="A2"/>

If it is can someone explain why such a restriction on schema validity has been set.

Thanks for the help,

[1] http://www.w3.org/TR/xmlschema-1/#coss-ct
Received on Wednesday, 30 May 2001 15:30:02 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:51 UTC