Collections
2 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Malli_Reddy
Posted On:   Sunday, December 3, 2006 10:18 AM

How can I sort the elements in the ArrayList obj?

Re: Collections

Posted By:   WarnerJan_Veldhuis  
Posted On:   Sunday, December 3, 2006 04:46 PM

Collections.sort( yourListHere, someComparatorHere );

Re: Collections

Posted By:   Anonymous  
Posted On:   Sunday, December 3, 2006 10:53 AM

why can't u use TreeSet for sorting, which allows sorting in both ascending as well as descending.
Note - insertion of all object of type should same.
About | Sitemap | Contact