Scoping of IDREF value space when doing selective validation

I think this may have been discussed along the way, but just in case:

From [1]:

"[Definition:]  IDREF represents the IDREF attribute type from [XML 1.0
Recommendation (Second Edition)]. The value space of IDREF is the set of
all strings that match the NCName production in [Namespaces in XML] and
have been used in an XML document as the value of an element or attribute
of type ID. The lexical space of IDREF is the set of strings that match the
NCName production in [Namespaces in XML].

NOTE: The value space of IDREF is scoped to a specific instance document."

From [2]:

"7.2 Assessing Schema-Validity of Documents

With a schema which satisfies the conditions expressed in Errors in Schema
Construction and Structure (7.1) above, the schema-validity of an element
information item can be assessed."

In other words, one can validate an element information item without
explicit reference to its parent or possible document context.  My
question:  if I validate:

     <E someattr="X"/>

and someattr has the datatype IDREF, how do I I know whether it is part of
a document such as:

          <A ID="X"/> <!-- makes attr below valid -->
          <E someattr="X"/>


          <E someattr="X"/>  <!-- invalid? -->

Similar considerations apply to key/keyref, I think?  As far as I can tell,
the structures spec. is self-consistent, but the datatype specification is
appealing to a notion of "document" that structures doesn't support well.
What am I missing?  I think we did discuss this, but can't remember the
resolution.  Thanks.


Noah Mendelsohn                                    Voice: 1-617-693-4036
Lotus Development Corp.                            Fax: 1-617-693-8676
One Rogers Street
Cambridge, MA 02142

Received on Tuesday, 2 January 2001 18:40:38 UTC