| Author |
Iterating same level nodes
|
John Best
Greenhorn
Joined: Oct 02, 2011
Posts: 9
|
|
Hi there,
<World>
<Country>Argentina</Country>
<Country>Bangladesh</Country>
<Country>China</Country>
<Country>Denmark</Country>
<Country>Iran</Country>
<Country>Iraq</Country>
</World>
how to iterate the above XML to get the Country's
Have a nice day
JB
|
 |
William Brogden
Author and all-around good cowpoke
Rancher
Joined: Mar 22, 2000
Posts: 12267
|
|
You need to get familiar with the standard Java library for manipulating XML.
Given the "World" org.w3c.Dom.Eement, you can getElementsByTagName("Country") to get a NodeList which you can use to iterate.
Bill
|
Java Resources at www.wbrogden.com
|
 |
 |
|
|
subject: Iterating same level nodes
|
|
|