W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2001

RE: NodeList (was RE: NamedNodeMap)

From: Joseph Kesselman <keshlam@us.ibm.com>
Date: Wed, 11 Jul 2001 16:57:50 -0400
To: www-dom@w3.org
Message-ID: <OFC5DA6AB2.F876A15D-ON85256A86.0070877B@pok.ibm.com>

>  I don't think the liveness requirement is described very carefully;

It's defined very carefully, though tersely. A somewhat more readable
description is available at http://www.w3.org/DOM/faq.html#nodelist

>if I have a node that I remove from the tree, and then add to another
>location, should the node be included in any NodeList objects returned
>from getElementsByTagName()?

The NodeList should always look as it would if you had just requested it.
When you remove the node, it drops out of the NodeList. When you insert it,
it will be inserted into the NodeList IF the insertiion point is within the
subtree of the node on which getElementsByTagName() was issued.  Note that
the location where it's inserted may be different from where it was
removed, since the NodeList displays the nodes in document order.




______________________________________
Joe Kesselman  / IBM Research
Received on Wednesday, 11 July 2001 16:58:26 GMT

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