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

Re: redefine and multiple includes

From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
Date: 05 Nov 2002 10:46:24 +0000
To: "Francis Brouns" <francis.brouns@ou.nl>
Cc: <xmlschema-dev@w3.org>
Message-ID: <f5b1y60pa4f.fsf@erasmus.inf.ed.ac.uk>

"Francis Brouns" <francis.brouns@ou.nl> writes:

> Hello,
> 
> I searched through the archives but could not find a solution.
> 
> I am creating 3 levels of a schema. Level a is the basis. Level b includes
> level a and redefines some groups and complexTypes. Level c includes level b
> and adds some more elements to those already added in level b. However it
> looks like the addition of level b are gone in level c, so I have to add
> those elements that I added in level b again in level c. Is this correct?
> 
> schema level a:
> <xs:group name="grp.on">
>   <xs:sequence>
>    <xs:element ref="description" minOccurs="0"/>
>   </xs:sequence>
>  </xs:group>
> 
> schema level b: redefine level a
> <xs:redefine schemaLocation="level-a.xsd">
> <xs:group name="grp.on">
>    <xs:sequence>
>     <xs:group ref="grp.on" minOccurs="0"/>
>     <xs:element ref="var" minOccurs="0" maxOccurs="unbounded"/>
>    </xs:sequence>
>   </xs:group>
> 
> 
> schema level c: redefine level b
> <xs:redefine schemaLocation="level-b.xsd">
> <xs:group name="grp.on">
>    <xs:sequence>
>     <xs:group ref="grp.on" minOccurs="0"/>
>     <xs:element ref="not" />
>    </xs:sequence>
>   </xs:group>
> 
> In level c the group grp.on should contain description, var and not, but it
> only contains description and not, unless I add var as well.

Should work as you have it, but I can't test it because XSV doesn't
support group redefinition -- which schema processor are you using?

ht
-- 
  Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
          W3C Fellow 1999--2002, 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/
 [mail really from me _always_ has this .sig -- mail without it is forged spam]
Received on Tuesday, 5 November 2002 05:46:30 GMT

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