commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Lea <ja...@kumachan.net.nz>
Subject Re: beanutils sort asc or desc
Date Sun, 04 Jan 2004 23:06:15 GMT
It should be sorting ascending as it will use natural ordering.  If you 
want to get it in descending order, then do this:

Collections.sort(historik, new BeanComparator("FROM_DATE"));
Collections.reverse(historik);



Søren Blidorf wrote:

>Hi.
>
>I am using the org.apache.commons.beanutils.*;
>
>Collections.sort(historik, new BeanComparator("FROM_DATE"));
>
>How can I decide whether the sort should be asc or desc
>
>BR
>
>Soren
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>
>  
>


-- 
Jason Lea



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message