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

Component representation of xs:group ref="x"

From: Michael Kay <mike@saxonica.com>
Date: Tue, 2 Nov 2004 23:49:42 -0000
To: <xmlschema-dev@w3.org>
Message-Id: <E1CP8PL-0004mZ-00@ukmail1.eechost.net>

I'm trying to understand the relationship of the schema component model of
particles and terms to the XML representation using xs:group elements.

In 3.9 we see

<xs:group ref="omelette" minOccurs="0"/>

as a representation of a Particle. A particle has a term, which is either a
model group, a wildcard, or an element declaration. A model group has a
compositor which is one of all, choice or sequence. There's no fourth kind
of particle that is a "model group reference".

So it seems that in order to construct the schema component model, we must
dereference the <xs:group ref="x"> and replace it with the contents of the
named model group (the model group definition) that it refers to. There
doesn't seem to be any schema component that contains a reference to a model
group definition. In fact, the model group definition itself seems to be
completely redundant as a schema component, because there is nothing that
refers to it.

Neither 3.9.2, which discusses particles, nor 3.8.2, which discusses model
groups, seems to explain how the <xs:group ref=""> representation is
translated into schema components. In fact, 3.9.2 seems to point you to
3.8.2, and 3.8.2 doesn't acknowledge the existence of named groups at all.

A similar kind of collapsing of XML representations into schema components
seems to occur with attribute groups. There is a schema component
corresponding to an attribute group definition, but there is no schema
component (other than the schema itself) that refers to it.

This seems to cause further havoc when trying to interpret section 5.3
(missing sub-components) and chameleon namespace behaviour. It seems to make
it increasingly difficult to decide whether xs:include and xs:redefine
operate on a set of schema components or on a set of XML representations.

Have I got the wrong end of the stick?

Michael Kay
Received on Tuesday, 2 November 2004 23:49:45 UTC

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