public interface SortKey
ServerSideSortRequestControl.
A sort key includes an attribute description and a boolean value that indicates whether the sort should be ascending or descending. It may also contain a specific ordering matching rule that should be used for the sorting process, although if none is provided it will use the default ordering matching rule for the attribute type.
Creation of SortKey is provided by
newSortKey(String, boolean, String)
| Modifier and Type | Method and Description |
|---|---|
java.util.Comparator<Entry> |
comparator()
Returns a
Comparator which can be used to compare entries using
this sort key. |
java.lang.String |
getAttributeDescription()
Returns the name of the attribute to be sorted using this sort key.
|
java.lang.String |
getOrderingMatchingRule()
Returns the name or OID of the ordering matching rule, if specified, which
should be used when comparing attributes using this sort key.
|
boolean |
isReverseOrder()
Returns
true if this sort key should be evaluated in reverse
(descending) order. |
java.util.Comparator<Entry> comparator() throws java.lang.IllegalArgumentException
Comparator which can be used to compare entries using
this sort key. The attribute description and matching rule, if present,
will be decoded using the default schema.Comparator.java.lang.IllegalArgumentException - If attributeDescription is not a valid LDAP string representation
of an attribute description, or if no ordering matching rule was
found.java.lang.String getAttributeDescription()
java.lang.String getOrderingMatchingRule()
null if the default ordering matching rule associated with
the attribute should be used.boolean isReverseOrder()
true if this sort key should be evaluated in reverse
(descending) order. More specifically, comparisons performed using the
ordering matching rule associated with this sort key will have their
results inverted.true if this sort key should be evaluated in reverse
(descending) order.