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

Re: conditional schemas

From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
Date: 29 Nov 2001 17:02:23 +0000
To: Eric van der Vlist <vdv@dyomedea.com>
Cc: Erik Beijnoff <erik@addsystems.com>, "'Lieve Laporte'" <lieve.laporte@uz.kuleuven.ac.be>, xmlschema-dev@w3.org
Message-ID: <f5bwv09y0gw.fsf@cogsci.ed.ac.uk>
consistent declaration rule
Eric van der Vlist <vdv@dyomedea.com> writes:

> Hi,
> 
> Erik Beijnoff wrote:
> 
> >  >In this case, wouldn't I have to duplicate everything that is
> > inside the "actions" element? 'Cause that's quite a lot...
> 
> >  >Regards, Lieve
> 
> > Ok, here goes...
> 
> > <xs:complexType name="outer">
> 
> >   <xs:choice>
> >     <xs:element name="action" type="actionsWithAccess"/>
> >     <xs:element name="action" type="actionsWithSettings"/>
> >   </xs:choice>
> > </xs:complexType>
> 
> 
> No, you can't do this (having two elements with the same name under a
> choice compositor) with W3C XML Schema since it would be breaking the
> famous Unique Particle Attribution rule:

It also breaks the Consistent Declaration rule, which forbids two
elements of the same name but different types.

ht
-- 
  Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
          W3C Fellow 1999--2001, part-time member of W3C Team
     2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
	    Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk
		     URL: http://www.ltg.ed.ac.uk/~ht/
Received on Thursday, 29 November 2001 12:02:29 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.