[XMLSCHEMA-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Type definition for empty element

From: Keith Suderman <suderman@cs.vassar.edu>
Date: Mon, 29 Nov 2004 16:24:43 -0500
To: xmlschema-dev@w3.org
Message-id: <5.1.1.6.0.20041129161354.021e3c88@pop.verizonemail.net>
definitions and empty
At 06:35 PM 11/26/2004 +0800, Simon.Cox@csiro.au wrote:
><complexType name="typeA">
>    <attribute name="att1" type="string"/>
></complexType>
>
>or
...
><complexType name="typeA">
>    <complexContent>
>       <restriction base="anyType">
>          <sequence/>
>          <attribute name="att1" type="string"/>
>       </restriction>
>    </complexContent>
></complexType>

I can't find anything to back up this assertion, but I had always thought 
these two definitions were the "same", that is, they both define an empty 
element with an attribute.  At least I use the first definition in our 
schemas and it seems to behave as I want/expect.

Cheers,
Keith

--------------------------------------------------
Keith Suderman
American National Corpus
suderman@cs.vassar.edu
http://americannationalcorpus.org
Received on Monday, 29 November 2004 21:26:01 GMT

Subscribe to the Stylus Scoop newsletter for helpful XML tips and tutorials.
Email
First Name
Last Name
Company

Download Stylus Studio 6 XML Enterprise Edition

Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.