Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


RE: redefine and interoperability problems

From: "Michael Kay" <mike@--------.--->
To: "'W. Eliot Kimber'" <ekimber@---------------.--->, <xmlschema-dev@--.--->
Date: 4/5/2007 10:41:00 AM
> > I personally think xs:redefine is one of those facilities 
> (xsi:nil is
> > another) where you're better off pretending it doesn't exist. 
> > Implementors don't have that luxury, but users do.
> 
> Hmm. The DITA schemas depend entirely on xs:redefine in order 
> to provide the equivalent configurability to the parameter 
> entities in the DTD versions, that is, using schemas can 
> redefine the members of groups that are then referenced from 
> the used schemas.

I have successfully tackled that problem by writing code that transforms
schemas (or near-schemas) to provide the configurability. I think it's
better to have this kind of capability in a separate language (indeed, a
separate architectural component of the system) rather than building in
self-modification semantics to the language itself.

I would have thought that the configurability you describe above could be
achieved by the even simpler technique of URI-switching - that is,
redirecting the URI in an xs:include to refer to a selected variant of the
included module.

xs:redefine is particularly horrible once schemas start to have wider scope
than a single validation episode, specifically, when multiple variants of a
schema component have to coexist. In particular, if you've got an XML
database whose contents are described by a family of schemas, the notion
that xs:redefine is "pervasive" could be taken to mean that it effectively
alters schemas that are used in a quite unrelated part of the database,
including schemas describing documents that were stored years ago. That's
clearly untenable; but finding a different definition of "pervasive" that
actually works in this environment isn't easy. Saxon's approach is to say
that once a schema component has been "used" (in some carefully defined
sense) further redefinition is banned. 

(Having said that, this problem affects any technique that leaves you with
multiple versions or variants of a schema component coexisting. I think
Roger Needham once said that all problems in computer science can be solved
by adding another level of indirection; and certainly the problem of
handling multiple coexisting versions of schema components appears insoluble
without adding a version/variant qualifier to the name of the component.)

Michael Kay
http://www.saxonica.com/


From jirka@k... Thu Apr 05 08:43:58 2007
Received: from maggie.w3.org ([193.51


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent