morgand 02/03/07 10:24:10 Modified: collections RELEASE-NOTES-2.0.html Log: added the new Comparator classes Revision Changes Path 1.4 +26 -1 jakarta-commons/collections/RELEASE-NOTES-2.0.html Index: RELEASE-NOTES-2.0.html =================================================================== RCS file: /home/cvs/jakarta-commons/collections/RELEASE-NOTES-2.0.html,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- RELEASE-NOTES-2.0.html 26 Feb 2002 22:10:39 -0000 1.3 +++ RELEASE-NOTES-2.0.html 7 Mar 2002 18:24:10 -0000 1.4 @@ -1,7 +1,12 @@ +<title>RELEASE NOTES: COLLECTIONS 2.0</title> + <center><h2>RELEASE NOTES: COLLECTIONS 2.0</h2></center> -<center><h3>NEW COLLECTIONS</h3></center> +<center><h3>NEW COLLECTIONS AND COMPARATORS</h3></center> + +<p>Collections 2.0 includes a significant number of new collections, in addition to several +useful Comparator classes.</p> <p>These collections are new to Collections 2.0:</p> @@ -39,6 +44,26 @@ <li><strong>TreeBag</strong> - An implementation of <strong>Bag</strong> that is backed by a TreeMap. Order will be maintained among the unique representative members.</li> +</ul> + +<p>These are the new Comparator classes:</p> + +<ul> +<li><strong>ComparableComparator</strong> - A Comparator that compares Comparable objects. + This Comparator is useful, for example, + for enforcing the natural order in custom implementations + of SortedSet and SortedMap.</li> +<li><strong>ComparatorChain</strong> - ComparatorChain is a Comparator that wraps one or + more Comparators in sequence. The ComparatorChain + calls each Comparator in sequence until either 1) + any single Comparator returns a non-zero result + (and that result is then returned), + or 2) the ComparatorChain is exhausted (and zero is + returned). This type of sorting is very similar + to multi-column sorting in SQL, and this class + allows Java classes to emulate that kind of behaviour + when sorting a List.</li> +<li><strong>ReverseComparator</strong> - Reverses the order of another comparator.</li> </ul>
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>