You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by Rahul Agarwal <re...@yahoo.com> on 2003/07/01 00:57:10 UTC
assigning ID to nodes
Hi,
Having a DOM tree, what can be the easiest way of assigning a unique ID attribute to each node? What if I want to assign to each node its height as well?
Regards,
Rahul.
---------------------------------
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
Re: assigning ID to nodes
Posted by Joseph Kesselman <ke...@us.ibm.com>.
To bind non-XML data to arbitrary nodes, see the prototype "user data"
hooks.
"Height" isn't an XML concept; that depends on how the XML markup is being
interpreted.
Either way, it sounds like you want to run a tree-walk, visit every node,
compute your additional data and attach it...
______________________________________
Joe Kesselman, IBM Next-Generation Web Technologies: XML, XSL and more.
"The world changed profoundly and unpredictably the day Tim Berners Lee
got bitten by a radioactive spider." -- Rafe Culpin, in r.m.filk
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org