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

Re: clarification on Unique Particle Attribution

From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
Date: 24 Oct 2001 16:18:18 +0100
To: sandygao@ca.ibm.com
Cc: www-xml-schema-comments@w3.org
Message-ID: <f5bhesp5ao5.fsf@cogsci.ed.ac.uk>
sandygao@ca.ibm.com writes:

> >From constraint "Unique Particle Attribution" [1] and appendix H [2], I
> couldn't figure out whether the following content model (<choice>) violates
> UPA constraint:
> 
> <group name="grp">
>   <sequence>
>     <element name="e"/>
>   </sequence>
> </group>
> 
> <choice>
>   <group ref="grp"/>
>   <group ref="grp" maxOccurs="3"/>
> </choice>
>
> In [1], it mentions "particle ... can be uniquely determined". But it's not
> clear to me whether such "particle" refers only to "non-group particle" or
> generic "particle". In the above example, there are two (different) group
> particles, but they refer to the same non-group particle. When we see an
> element "e" in the instance, we can uniquely determine the non-group
> particle for validation, but not a unique group particle.

The UPA applies to components, not representations, so particles _are_ 
the right thing to worry about.

But the above is still in violation, because it corresponds to the
same component that

  <choice>
   <sequence>
     <element name="e"/>
   </sequence>
   <sequence max='3'>
     <element name="e"/>
   </sequence>
  </choice>

corresponds to.

For the purposes of UPA, the sequences are themselves irrelevant, so
we get

  <choice>
     <element name="e"/>
     <element name="e" maxOccurs="3"/>
  </choice>

which clearly violates the UPA.

> [1] http://www.w3.org/TR/xmlschema-1/#cos-nonambig

> [2] http://www.w3.org/TR/xmlschema-1/#non-ambig

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 Wednesday, 24 October 2001 11:17:31 GMT

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