W3C home > Mailing lists > Public > xmlschema-dev@w3.org > October 2001

Re: clarification/errata: circular attributeGroup, ur-type & include

From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
Date: 25 Oct 2001 09:20:52 +0100
To: sandygao@ca.ibm.com
Cc: www-xml-schema-comments@w3.org, xmlschema-dev@w3.org
Message-ID: <f5bvgh42krf.fsf@cogsci.ed.ac.uk>
sandygao@ca.ibm.com writes:

> Further on this topic:
> 1. If schema document A includes B, and B includes C. Does A have access to
> components in C? And does C have access to A?

The phrase 'have access' is possibly misleading.  Any schema document
can legally contain a reference to any name in its own target
namespace.  It can only contain references to names in other
namespaces if it contains <import>s for those namespaces.  So the
following is _not_ valid, regardless of whether it's
chameleon-included by a schema with target namespace of 'urn:xyzzy' or

<xs:schema xmlns:x="urn:xyzzy">
 <xs:element name="foo" type="x:baz"/>

The question of whether references are satisfied is a matter which can 
only be addressed at runtime, once the complete set of available
components and their names is known.

> I think the answer is yes, according to your explanation below.

So indeed in your example, references in C may be satisfied by
components declared in A.

> 2. If schema document A includes B, and B *imports* C. Does A have access
> to components in C?

See above -- no.

  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 Thursday, 25 October 2001 04:20:06 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:14:54 UTC