W3C home > Mailing lists > Public > xmlschema-dev@w3.org > April 2011

Re: multiply-connected graph of schema import

From: Michael Kay <mike@saxonica.com>
Date: Fri, 15 Apr 2011 11:57:24 +0100
Message-ID: <4DA82494.80507@saxonica.com>
To: xmlschema-dev@w3.org
On 14/04/2011 14:15, Paul Harrison wrote:
> Is a multiply-connected (but non-circular) graph of schema imports allowed?
>
> e.g  B imports A
>         C imports B
>         D imports C and A
>
> Some tools seem to get a little confused by this sort of thing
>
> Regards,
> 	Paul
>
>
It's not only allowed, it's often essential.

The rule is that if a schema document A references a schema component in 
namespace N, then it must include an xs:import for namespace N.

It's true however that the rules in the spec leave a lot to be desired 
(XSD 1.1 improves them, though not as much as I would like), and as a 
result, implementations are not 100% consistent.

xs:include is different - there's never a need to have circular 
includes, but they certainly shouldn't cause any problems if you do.

Michael Kay
Saxonica
Received on Friday, 15 April 2011 10:57:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 15 April 2011 10:57:50 GMT