cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam Ratcliffe" <>
Subject RE: Sorting elements before jx:forEach ?
Date Sun, 12 Dec 2004 22:59:38 GMT
Hi Laurent

You can use the java.util.Collections class to sort a list using either the
natural ordering of the elements or by supplying a Comparator.  You just
need to import these classes into your flowscript to use them.


-----Original Message-----
From: Laurent Perez []
Sent: Friday, 10 December 2004 9:02 a.m.
Subject: Sorting elements before jx:forEach ?


Is it possible to directly sort elements (say, by some random bean
property) within the JXTemplate itself before looping over an
ArrayList received from a flowscript with <jx:forEach>, or is the best
practice to sort them before they reach the JXTemplate ? And if so,
how would you sort them within a flowscript ?

Thanks for any advice

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message