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

duplicate element declaration

From: Tinny Ng <tng-xml@ca.ibm.com>
Date: Wed, 16 May 2001 06:52:36 -0700
Message-ID: <3B028623.BA5F2416@ca.ibm.com>
To: xmlschema-dev@w3.org
According the schema spec, we are allowed to have duplicate element
declaration within the same scope as long as they are of the same type,
i.e.

<element name="root">
 <complexType>
  <sequence>
   <element name="A" type="string"/>
   <element name="A" type="string"/>
  </sequence>
 </complexType>
</element>

But if the second has substitutionGroup specified, i.e.

<element name="root">
 <complexType>
  <sequence>
   <element name="A" type="string"/>
   <element name="A" type="string" substitutionGroup="ipo:comment"/>
  </sequence>
 </complexType>
</element>

then

1.  If this valid?
2.  If so, do we ignore the substitution group for the second element?
3.  or does the first element have the same substitution group
automatically?
4.  or ..?

Thanks!

Tinny
Received on Wednesday, 16 May 2001 09:52:56 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:20 GMT