public class Sort
extends java.lang.Object
<c:forEach items="${openmrs:sort(someListObject)}" var="o" end="0"> .... .... </c:forEach>
Constructor and Description |
---|
Sort() |
Modifier and Type | Method and Description |
---|---|
static <T> java.util.List<T> |
sort(java.util.Collection<T> c)
This method will sort a collection based on the natural order of it's elements
|
static <T extends java.lang.Comparable<T>> |
sort(java.util.Collection<T> c,
java.lang.Boolean reverseOrder)
This method will sort a collection based on the natural order of it's elements
|
static <T> java.util.List<T> |
sort(java.util.Collection<T> c,
java.lang.String sortProperty,
java.lang.Boolean reverseOrder)
This method will sort a passed Collection
|
public static <T> java.util.List<T> sort(java.util.Collection<T> c)
c
- public static <T extends java.lang.Comparable<T>> java.util.List<T> sort(java.util.Collection<T> c, java.lang.Boolean reverseOrder)
c
- isDescending
- public static <T> java.util.List<T> sort(java.util.Collection<T> c, java.lang.String sortProperty, java.lang.Boolean reverseOrder)
c:
- The collection to sortsortProperty:
- The javabean property to sort the elements of the Collection byisDescending:
- Boolean indicating whether or not to reverse the order of the collectionCopyright © 2018 OpenMRS Inc.. All Rights Reserved.