[jdom-interest] JDOM Parsing - Iterating Through Elements Named the Same

Hunter Hillegas timebomb at west.net
Mon Dec 10 11:40:23 PST 2001

I have an XML file like this:

    <service id="0"><stuff></stuff></service>
    <service id="1"><stuff></stuff></service>
    <service id="9"><stuff></stuff></service>

There can be an arbitrary number of <service> elements, but I always want
the last one.

Is there a way to iterate through elements that have the same name to get to
the end?

What is the best way to do this?


More information about the jdom-interest mailing list