| Modifier and Type | Field and Description | 
|---|---|
static Comparator<Object> | 
COMPARATOR
Provide a comparator for collections. 
 | 
static Comparator<Object> | 
REVERSE_COMPARATOR
Provide a comparator, in reversed order, for collections. 
 | 
| Constructor and Description | 
|---|
OrderUtil()  | 
| Modifier and Type | Method and Description | 
|---|---|
static void | 
reverseSort(List<?> list)
Sort the given list. 
 | 
static void | 
reverseSort(Object[] array)
Sort the given array in reverse order. 
 | 
static void | 
sort(List<?> list)
Sort the given list. 
 | 
static void | 
sort(Object[] objects)
Sort the given array. 
 | 
static void | 
sort(Ordered... objects)
Sort the given array. 
 | 
static <T> Stream<T> | 
sort(Stream<T> list)
Sort the given list. 
 | 
public static final Comparator<Object> COMPARATOR
public static final Comparator<Object> REVERSE_COMPARATOR
public static void sort(List<?> list)
list - The list to sortpublic static <T> Stream<T> sort(Stream<T> list)
T - The stream generic typelist - The list to sortpublic static void reverseSort(List<?> list)
list - The list to sortpublic static void reverseSort(Object[] array)
array - The array to sortpublic static void sort(Ordered... objects)
objects - The array to sortpublic static void sort(Object[] objects)
objects - The array to sort