public class EntityValuesComparator<T> extends AbstractComparator<T>
For example, to obtain a Comparator
that compares com.haulmont.cuba.core.entity.Entity
objects
by some property that is specified by com.haulmont.chile.core.model.MetaPropertyPath
:
Comparator.comparing(e -> e.getValueEx(propertyPath), EntityValuesComparator.of(asc))
Modifier and Type | Field and Description |
---|---|
static java.util.Comparator<java.lang.Object> |
NATURAL_ORDER |
static java.util.Comparator<java.lang.Object> |
REVERSE_ORDER |
asc, metadata, nullsLast
Modifier | Constructor and Description |
---|---|
protected |
EntityValuesComparator(boolean asc) |
Modifier and Type | Method and Description |
---|---|
static java.util.Comparator<java.lang.Object> |
asc(boolean asc) |
int |
compare(T o1,
T o2) |
protected java.lang.Object |
transformValue(T value) |
__compare, compareAsc