W3C home > Mailing lists > Public > xmlschema-dev@w3.org > December 2004

RE: UPA violation or not?

From: <noah_mendelsohn@us.ibm.com>
Date: Thu, 16 Dec 2004 11:53:25 -0500
To: "Michael Kay" <mike@saxonica.com>
Cc: "'Morris Matsa'" <mmatsa@us.ibm.com>, xmlschema-dev@w3.org
Message-ID: <OF7472DCE7.AD40436E-ON85256F6C.005CFB86@lotus.com>

Well, I agree that the wording is at best unfortunate, but if (a?, a?) 
doesn't violate UPA, then I can't see why we have the rule at all!  It 
seems like the most basic case.  FWIW:  I think our intentions were clear, 
at least among ourselves, and if the rec doesn't clearly set them out it 
should be clarified.  I would be very unhappy if the clarification 
resulted in your example or (a?, a?) passing a UPA test.  That seems the 
worst of both worlds:  you don't get the direct particle assignment that 
mapping tools and other higher level software can find beneficial, and you 
don't get the non-deterministic flexibility that let's you express more 
powerful constraints, as in Relax-NG.

Noah Mendelsohn 
IBM Corporation
One Rogers Street
Cambridge, MA 02142

"Michael Kay" <mike@saxonica.com>
12/16/2004 10:29 AM

        To:     <noah_mendelsohn@us.ibm.com>, "'Morris Matsa'" <mmatsa@us.ibm.com>
        cc:     <xmlschema-dev@w3.org>
        Subject:        RE: UPA violation or not?

> Is there a subtlety in the example that I am missing?  It's 
> true that the 
> two particles have the same value for {term}, but that 
> doesn't make them the same particle. 

I think this is indeed the subtlety: the Thompson/Tobin algorithm doesn't
report this as a UPA violation because it is treating two element 
that refer to the same element declaration as equivalent.

There's some comfort for this interpretation in the spec: "A content model
must be formed such that during .validation. of an element information 
sequence, the particle component contained directly, indirectly or
.implicitly. therein with which to attempt to .validate. each item in the
sequence in turn can be uniquely determined".

(Who wrote this stuff?)

-- it's the element declaration that's used to validate the item in the
sequence, not the particle itself, so identifying an element declaration
uniquely is sufficient to achieve the stated purpose.

-- the term "implicitly contains" is hyperlinked to the definition "A list
of particles implicitly contains an element declaration if a member of the
list contains that element declaration in its .substitution group.", which
suggests that element declarations as well as particles play a role here.
Although it says we're looking for unique particles, the "implicitly
contains" definition only works if we're actually looking for unique 
declarations. Normally this is a stronger constraint, because each element
particle refers to a set of element declarations (the substitution group);
but in this case it is a weaker constraint, because two particles refer to
the same declaration.

-- Appendix H confuses things even further by referring to "element
declaration particles".

Michael Kay
Received on Thursday, 16 December 2004 16:59:06 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:56:07 UTC