W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > January to March 2001

Pointless use of simpleType

From: James Clark <jjc@jclark.com>
Date: Sun, 11 Feb 2001 19:16:49 +0700
Message-ID: <3A8682B1.377365A@jclark.com>
To: XML Schema Comments <www-xml-schema-comments@w3.org>
Why does XML Schema Part 2 require me to write for example

<xsd:simpleType>
   <xsd:list>
      <xsd:simpleType>
	 <xsd:union memberTypes="xsd:NCName">
            <xsd:simpleType>
               <xsd:restriction base="xsd:token">
                  <xsd:enumeration value="#default"/>
               </xsd:restriction>
            </xsd:simpleType>
	 </xsd:union>
      </xsd:simpleType>    
   </xsd:list>
</xsd:simpleType>

instead of simply:

<xsd:list>
   <xsd:union memberTypes="xsd:NCName">
      <xsd:restriction base="xsd:token">
         <xsd:enumeration value="#default"/>
      </xsd:restriction>
   </xsd:union>    
</xsd:list>

?

The extra simpleType elements are completely unnecessary, as far as I
can see, and serve only to obfuscate the meaning of the Schema.

James
Received on Sunday, 11 February 2001 08:19:41 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 6 December 2009 18:12:49 GMT