Re: Adding children to type derived by restriction

Mark Feblowitz <mfeblowitz@frictionless.com> writes:

> I sent a similar message to Henry, but I also thought it would be useful to
> break it open for wider discussion. 
> 
> I am part of a team that is developing the Open Application Group's XML
> Schema version of the OAGIS standard. Before we commit the grievous sin of
> including illegal Schema constructs in a proposed standard(!), we thought it
> a good idea to ask about particular usage that we're unsure of. 
> 
> There seem to be diverse interpretations regarding allowable derivations of
> complex types by restriction. The issue at hand is that of adding a new
> child element to a complex type that has been derived by restriction.

I'm not aware of anyone ever claiming this was allowed by the REC.
It's not.

> Our understanding, based on reading the Schema Structures spec, is
> that this is not allowed. But XML Spy, Xerces, and XSV allow this
> behavior.

XSV's documentation [1] lists:

 "Detailed enforcement of derivation by restriction"

in the Not Implemented Yet section.

The key invariant, which you don't need a validator to check, is that
every member of the derived type must be a member of the base type.
Adding a new child clearly breaks that.

ht

[1] http://www.ltg.ed.ac.uk/~ht/xsv-status.html
-- 
  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 Tuesday, 6 November 2001 11:28:30 UTC