JAVA DOM Parsing XML File without getting elements by tag name

firepower121

New Member
I have an XML file with the following structure (I need it to have knowledge base rules):\[code\]<center> <games> <game> <title> <genre> <price> ... etc </game> </games> <rules> <rule> <if> <game>X</game> <genre>Shooter</genre> </if> <then> <price>40</price> </then> </rule> </rules></center>\[/code\]How can I parse the games and rules node separately, so as not to mix the tags that appear in both nodes? I've been using getElementsByTagName when I needed to parse XML files but it obviously won't help me here. Thanks!
 
Back
Top