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

Re: Should Document.cloneNode() work in Level 1?

From: John Cowan <cowan@locke.ccil.org>
Date: Wed, 09 Sep 1998 12:43:52 -0400
Message-ID: <35F6B048.D6143BE8@locke.ccil.org>
To: DOM List <www-dom@w3.org>
I don't really understand what the problem is.  Document.cloneNode
with a shallow copy would just be another Document identical to this
one but without children.  For a deep copy, do a shallow copy and
then traverse the tree below this Document.  For each Node, invoke the
proper createXXX factory method on the new Document and copy all the
(IDL) attributes: then insert it into place in the new tree.

Am I missing something?

-- 
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 Wednesday, 9 September 1998 12:45:30 GMT

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