Re: xmlschema does not support principle of substitutability of subty pe for its supertype

There are various namespace-related problems with your example files
as they stand at the moment, but correcting for those, the principle
you are addressing is clear and the problem likewise:  type
substitutability is not the same as element substitutability.
(Element) substitution groups provide the functionality you want.

Make all your vertebrates substitutable for Vertebrate (:-) and your
problem will be solved:

<xsd:element name="Bird" type="BirdType" substitutionGroup="Vertebrate"/>
<xsd:element name="BirdOfPrey" type="BirdOfPreyType" substitutionGroup="Bird"/>
etc.

You'll probably also want to make at least Vertebrate, if not Bird
etc. as well, abstract='true'.

ht
-- 
  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, 30 November 2000 07:45:47 UTC