[jdom-interest] Reverse order of children

Alex Rosen arosen at silverstream.com
Wed Apr 17 08:07:15 PDT 2002


If you want to reverse the order of the children, you could use something
similar to the code I posted recently to sort child elements. Just replace
the sort() code with some code that reverses the children.

http://www.servlets.com/archive/servlet/ReadMsg?msgId=211785&listName=jdom-i
nterest

If you just want to access the children in reverse order, why not just
traverse the list backwards?

Alex

> -----Original Message-----
> From: jdom-interest-admin at jdom.org
> [mailto:jdom-interest-admin at jdom.org]On Behalf Of Lendholt Matthias
> Sent: Wednesday, April 17, 2002 7:35 AM
> To: jdom-interest at jdom.org
> Subject: [jdom-interest] Reverse order of children
>
>
> Hi all,
>
> what is the best way to get a list of all children (of an
> element) in the
> reverse order ? Neither Element nor List have a function for that.
>
> Thanks,
>
> Matthias Lendholt
> ----
> Fon: +49-30-386-23484
> Siemens AG, Berlin (Germany)
> _______________________________________________
> To control your jdom-interest membership:
> http://lists.denveronline.net/mailman/options/jdom-interest/yo
> uraddr at yourhost.com




More information about the jdom-interest mailing list