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

Re: Including schemas with no targetnamespace

From: Kohsuke KAWAGUCHI <kohsuke.kawaguchi@sun.com>
Date: Mon, 15 Oct 2001 16:15:35 -0700
To: Jeff Lowery <jlowery@scenicsoft.com>, xmlschema-dev@w3.org
Message-Id: <20011015155808.065C.KOHSUKE.KAWAGUCHI@sun.com>

> > <schema> <!-- no target namespace -->
> >   
> >   <simpleType name="xyz">
> >     <restriction base="foo">    (3)
> >       ...
> >     </restriction>
> >   </simpleType>
> > </schema>
> Well, this schema is certainly not valid standalone.

But it's OK for a schema to be incorrect (invalid) as a standalone
schema. It's OK as long as the entire schema set is correct.

> I've read some of Roger Costello's work, and it's fair to
> guess that he would probably consider this a feature, but to my eyes it's a
> bug. Maybe that's just pig-headed narrowmindedness on my part.

I do think that the chameleon feature is error-prone. All I wanted to
point out is that the spec has a significant problem on this issue, and
it's not going to be easy to fix it.

To me, the chameleon schema feature is a kind of transformation: a
transformation that introduces the targetNamespace attribute and an xmlns
declaration. There are other transformations that people want to use: for
example, some people want to have conditional blocks in schemas. Other
people want to have a feature that resembles to the templates of C++.

It's not clear why the chameleon feature, just one of many useful
transformations, has to be added to the core XML Schema spec, especially
considering the complexity involving in implementing and specifying it.

Kohsuke KAWAGUCHI                          +1 650 786 0721
Sun Microsystems                   kohsuke.kawaguchi@sun.com
Received on Monday, 15 October 2001 19:15:26 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:53 UTC