Re: [Spam?] Why do you allow vendors to publish interfaces using org.w3c.dom

Robert W. McKitrick Jr. wrote:
> 
> Why do you allow vendors to publish interfaces using org.w3c.dom?

Not only we allow them but we require them to do so. Interoperability is
the only reason for the DOM. So, the same package name must be used in
every DOM implementation to achieve this. Otherwise, one would have to
change his code everytime he wants to run his code against a different
DOM implementation - meaning we failed to achieve our goal.

> The W3C has broken a major rule of "Programming by contract!" In the
> face of a changing interface (no pun intended) the W3C should insist on
> a vendor unique package prefix (e.g. com.rwmj.org.w3c.dom). It is
> impossible to mix code using two different versions of the org.w3c.dom
> interfaces.

Oh well, we can't win on all fronts I guess. Given that I expect this
scenario to be less common than the one I described I still think we
made the right choice.

> Furthermore, code written to one version as implemented by
> one vendor will not run on another vendors implementation of the
> org.w3c.dom interfaces if using a newer version.

This is not always true actually. Code compiled against an old version
will run on an implementation based on a newer version, granted we've
only added methods to the interfaces.

> For example, DataChannel's DXP 1.0 beta-d and IBM's XML for Java 1.0.4
> cannot co-exist because of this.

First I have to point out that both are based on a Working Draft,
therefore this argument is not quite relevant for now. But I'll grant
you that the problem will exist with further versions of the DOM. We've
not actually discussed how we will address this kind of problem but one
simple solution is to never change these interfaces. Instead we could
simply define new ones, possibly in another package such as
org.w3c.dom2.
-- 
Arnaud Le Hors - W3C, User Interface Domain - www.w3.org/People/Arnaud

Received on Friday, 14 August 1998 08:51:23 UTC