List of utility methods to do Collection Sort
List | sorted(Collection Similar to #sorted(Collection,Comparator) using the Comparable interface of the given elements final Comparator<E> comparator = null; return sorted(collection, comparator); |
List | sorted(Collection sorted final List<String> sorted = new ArrayList<>(ss); Collections.sort(sorted); return sorted; |
List | sorted(Collection sorted return sorted(c, false);
|
List | sorted(Collection sorted ArrayList<T> list = new ArrayList<T>(c); Collections.sort(list); return list; |
List | sorted(Collection Get a sorted list representation of a collection. List<T> res = new ArrayList<>(collection); Collections.sort(res); return Collections.unmodifiableList(res); |
List | sortedByName(Collection sorted By Name if (unsorted == null) { return Collections.emptyList(); List<T> retList = removeExclusionsFrom(unsorted, comparator, exclusions); Collections.sort(retList, comparator); return retList; |
Iterable | sortedCollection(final Comparator super T> comparator, final Collection sorted Collection if (input.size() > 1) { final List<T> ret = new ArrayList<>(input); Collections.sort(ret, comparator); return ret; } else { return input; |
List | sortedIfPossible(Collection sorted If Possible List<T> result = new ArrayList<>(collection); try { Collections.sort((List) result); } catch (ClassCastException e) { } catch (NullPointerException npe) { return result; |
List | sortEntities(Collection Sorts elements provided in entities .
List<T> entityList = new ArrayList<T>(entities); Collections.sort((List) entityList, comparator); return entityList; |
List | sortMapByValues( final Map sort Map By Values final List<Map.Entry<String, Collection<T>>> sorted = new ArrayList<Map.Entry<String, Collection<T>>>( related_region_counts.entrySet()); Collections.sort(sorted, comparator); return sorted; |