All apologies if this is a really obvious question but after 3+ hours
searching this group and the tubes in general I couldn't find the
answer.
I have xml data that looks like this:
<root>
<item>
<item-description>a</item-description>
<item-weight>5</item-weight>
<item-color>blue</item-color>
</item>
</root>
The data is in a document object and I've retrieved the node "item".
I want to retrieve the value of item-weight. The element isn't always
the second child and doesn't always exist. From what I can tell by
reading the docs I would have to retrieve the node list containing all
of the children of item, test each one to see if it was named "item-
weight", the retrieve the value of the node that tests positive.
Please tell me there is a more efficient way to do his because I'm
pretty sure there would be performance issues when this operation has
to be performed a few dozen (few hundred) times.
AC
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---