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

Re: <restriction> is not actually a restriction

From: Kohsuke KAWAGUCHI <kohsuke.kawaguchi@sun.com>
Date: Mon, 26 Nov 2001 16:16:15 -0800
To: ht@cogsci.ed.ac.uk (Henry S. Thompson)
Cc: xmlschema-dev@w3.org
Message-Id: <20011126161209.DBBA.KOHSUKE.KAWAGUCHI@sun.com>
Re: <restriction> is not actually a restriction

> You're right -- I could have sworn we put something in about that, but
> I don't see it -- I guess I'm thinking of defaults, which we did
> catch.  This could/should perhaps be fixed independently of revisiting 
> restriction in general.

Thanks for the info.

There is another similar problem:

<xs:complexType name="B">
  <xs:anyAttribute namespace="#all" processContents="lax"/>
  <xs:attribute name="foo" type="xs:integer" use="optional"/>
</xs:complexType>

<xs:complexType name="D">
  <xs:complexContent>
    <xs:restriction base="B">
      <xs:attribute name="foo" type="xs:integer" use="prohibited" />
    </xs:restriction>
  </xs:complexContent>
</xs:complexType>


Even though @foo is prohibited explicitly, it is allowed because it's
accepted by the #all wildcard. <XXX foo="str"/> is not valid with
respect to B, but is valid with respect to D.


regards,
--
Kohsuke KAWAGUCHI                          +1 650 786 0721
Sun Microsystems                   kohsuke.kawaguchi@sun.com
Received on Monday, 26 November 2001 19:16:12 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.