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

Re: include

From: Jeni Tennison <jeni@jenitennison.com>
Date: Wed, 12 Dec 2001 19:08:00 +0000
Message-ID: <1611883567.20011212190800@jenitennison.com>
To: "florent" <florent@inovo.be>
CC: xmlschema-dev@w3.org
Hi Florent,

> Hello, I am looking for help about <xs:include ... />
>
> let's say my schema 'a.xsd' includes one other schemas :  'b.xsd'  
> The thing is I want to declare/use some similars elements in 'a.xsd' and 'b.xsd' . 
> These common elements are declared in 'c.xsd' . 
> Do I have to include 'c.xsd' in 'a.xsd' and in 'b.xsd'
> or in 'b.xsd' only? 
> or in 'a.xsd' only? 

Any of those are fine. The schema validator gathers together all the
included schema to make one big schema for the target namespace, and
any of those methods make the schema components in c.xsd available
within that schema.

Personally, I'd definitely include c.xsd in b.xsd as that means b.xsd
could be used elsewhere. Whether you include c.xsd in a.xsd is up to
you, but I'd probably would do that too.

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/
Received on Wednesday, 12 December 2001 14:08:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:25 GMT