RE: Implementing NodeList

> I think the best implementation is to lazily evaluate the NodeList, i.e.,
> make the NodeList be an interface that really has what we used to call a
> NodeIterator under the covers.  That way, you only see nodes in the tree
> when the user asks for them.  That puts the burden of capturing changes to
> the tree on the call to item().

The other pattern to use is Observer. Make the NodeList and Observer of the
Document so that they automgically update themselves.

Received on Tuesday, 28 July 1998 11:33:40 UTC