W3C home > Mailing lists > Public > www-dom@w3.org > October to December 1998

Re: XML APIs

From: John Cowan <cowan@locke.ccil.org>
Date: Tue, 03 Nov 1998 15:08:38 -0500
Message-ID: <363F62C6.F86BA5A8@locke.ccil.org>
To: DOM List <www-dom@w3.org>
Stephen R. Savitzky wrote:

> I think that this may be at the very core of our disagreement.

I think there is an even more basic problem.  You want the DOM to be
a parse tree API, whereas I know that it isn't.  You consider this
a specification bug, I consider this a fact of life.  :-)

> Iterators
> _are_ useful, even with limitations.  My application, for example, treats
> parse trees as immutable.  Requiring my implementation to account for their
> potential mutability imposes a very large overhead that I am unwilling to
> pay.

Then you are not a plausible customer for DOM Level 1 as it is, which
not only has a bunch of methods for creating, destroying, and removing
nodes and subtrees, but presumes the existence of a hidden DOM
builder which can create things for which there is no API, and
asynchronously too.

This does not mean you are not a morally worthy person.  :-) again.

> An additional problem is that in garbage-collected languages there is no
> good way to identify ``dead'' iterators, which no longer have to be
> updated.

I agree completely; this is a serious problem in DOM implementation
strategy.  But just overriding it is like claiming to implement
Algol 60 while ignoring call-by-name, or Java while ignoring
dynamic class loaders: useful for some, possibly many, purposes,
but not a conformant implementation.

> Indeed.  That is _precisely_ my point.  It is this kind of surprise that
> makes the specification erroneous.

Erroneous or not, implementers are bound by its contract.

> Excuse me.  Values _do_ have state; it's just that you can't _change_ that
> state.

Okay, if you like.  I use the term "state" to imply mutability; I do
not think, e.g. that the value of (the float 3.0) is part of its state.

> > and for "dart boards" that react to whatever's posted to (thrown at?)
> > them, but not for anything with any liveness.  A robot modeled by such a
> > "natural model" would be more like a Barbie doll: poseable, but unable
> > to move by itself.

I should have clarified that I meant an AI-type robot, not an
industrial one.

> All I'm insisting on is that _if there are no other
> active threads of control in the robot's computer_, that the values I put
> into its joint positions be the same as the ones I get out after it has
> stopped moving.

No such luck, doc!  If you put the robot's joints into certain
positions, it will fall over under the influence of gravity, and the
values you get back will be quite different from what you put in.
Your "natural model" is then useless.
 
That is what I mean by "liveness": subject to influence by outside
forces.  In the case of the DOM, the DOM builder.

-- 
John Cowan	http://www.ccil.org/~cowan		cowan@ccil.org
	You tollerday donsk?  N.  You tolkatiff scowegian?  Nn.
	You spigotty anglease?  Nnn.  You phonio saxo?  Nnnn.
		Clear all so!  'Tis a Jute.... (Finnegans Wake 16.5)
Received on Tuesday, 3 November 1998 15:07:36 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:46 GMT