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

Re: Omission in <element> constraint in Schema Structures spec

From: <mhuffman@ca.ibm.com>
Date: Tue, 6 Mar 2001 08:32:15 -0500
To: ht@cogsci.ed.ac.uk
Cc: www-xml-schema-comments@w3.org
Message-ID: <OFFBE6742A.42DB696B-ON85256A07.00485CAF@torolab.ibm.com>
Thank you, Henry.

I see in SforS that attributes "substitutionGroup" and "final" have use
="prohibited" for local elements.  That leaves "abstract" and "form".
I don't believe they apply to a local element with ref="...".  Is this
explicitly specified somewhere else in the spec documents? If not, can they
simply be added to the other "must be absent" attributes in the constraint
I referenced below?

One of my roles here is developing test cases to ensure IBM and Xerces XML
Parsers properly enforce all schema component constraints.  I need to
reference a specific section in a spec document which clearly states the
constraint being tested.

Thanks again.
Mark Huffman
XML Parsers, Toronto Lab
(416) 448-2332     T/L 778

---------------------- Forwarded by Mark Huffman/Toronto/Contr/IBM on
03/06/2001 08:12 AM ---------------------------

ht@cogsci.ed.ac.uk (Henry S. Thompson) on 03/05/2001 11:29:22 AM

Please respond to ht@cogsci.ed.ac.uk (Henry S. Thompson)

To:   Mark Huffman/Toronto/Contr/IBM@IBMCA
cc:   www-xml-schema-comments@w3.org
Subject:  Re: Omission in <element> constraint in Schema Structures spec

mhuffman@ca.ibm.com writes:

> The XML Schema Structures spec has a constraint on <element>s whose
> is not <schema> which reads:
>  If ref is present, then all of <complexType>, <simpleType>, <key>,
>  <keyref>, <unique>, nullable(nillable), default, fixed, block and
>  type must be absent, i.e. only minOccurs, maxOccurs, id are allowed
>  in addition to ref, along with <annotation>.
> This is in "Schema Representation Constraint: Element Declaration
> Representation OK" (CR spec section 4.3.2 ... Current (Feb 10/2001) spec
> section 3.3.3).  This constraint omits the 4 other attributes of
> - abstract, final, form, and substitutionGroup.
> My assumption is that these 4 attributes also "must be absent" if ref is
> present, otherwise the schema would be in error.

That those attributes are forbidden is enforced by the schema for
schemas.  The explicit representation constraints in the relevant
(sub-)sections are all introduced as being _in addition_ to the
constraints in the SforS.

  Henry S. Thompson, HCRC Language Technology Group, University of
          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 Tuesday, 6 March 2001 08:32:35 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:49:54 UTC