Package java.util
Class Collections
static Comparator reverseOrder()
_INSERT_METHOD_SIGNATURE_HERE_
Returns a comparator that imposes the reverse of the natural ordering on a collection of objects that implement the Comparable interface. (The natural ordering is the ordering imposed by the objects' own compareTo method.) This enables a simple idiom for sorting (or maintaining) collections (or arrays) of objects that implement the Comparable interface in reverse-natural-order. For example, suppose a is an array of strings. Then
Arrays.sort(a, Collections.reverseOrder());
sorts the array in reverse-lexicographic (alphabetical) order. The returned comparator is serializable.