Class BaseQuerySort
-
- All Implemented Interfaces:
-
io.getstream.chat.android.models.querysort.QuerySorter
public abstract class BaseQuerySort<T extends Object> implements QuerySorter<T>
Base class for implementing QuerySorter. This class holds common code for QuerySortByField and QuerySortByReflection.
-
-
Field Summary
Fields Modifier and Type Field Description private List<SortSpecification<T>>sortSpecificationsprivate final Comparator<in T>comparator
-
Constructor Summary
Constructors Constructor Description BaseQuerySort()
-
Method Summary
Modifier and Type Method Description List<SortSpecification<T>>getSortSpecifications()Sort specifications that compose this QuerySorter UnitsetSortSpecifications(List<SortSpecification<T>> sortSpecifications)Sort specifications that compose this QuerySorter Comparator<in T>getComparator()abstract Comparator<T>comparatorFromFieldSort(SortAttribute.FieldSortAttribute<T> firstSort, SortDirection sortDirection)Comparator from SortAttribute.FieldSortAttribute abstract Comparator<T>comparatorFromNameAttribute(SortAttribute.FieldNameSortAttribute<T> name, SortDirection sortDirection)Comparator from SortAttribute.FieldNameSortAttribute List<Map<String, Object>>toDto()Converts the sorter to a DTO. IntegerhashCode()StringtoString()Booleanequals(Object other)-
-
Method Detail
-
getSortSpecifications
List<SortSpecification<T>> getSortSpecifications()
Sort specifications that compose this QuerySorter
-
setSortSpecifications
Unit setSortSpecifications(List<SortSpecification<T>> sortSpecifications)
Sort specifications that compose this QuerySorter
-
getComparator
Comparator<in T> getComparator()
-
comparatorFromFieldSort
abstract Comparator<T> comparatorFromFieldSort(SortAttribute.FieldSortAttribute<T> firstSort, SortDirection sortDirection)
Comparator from SortAttribute.FieldSortAttribute
-
comparatorFromNameAttribute
abstract Comparator<T> comparatorFromNameAttribute(SortAttribute.FieldNameSortAttribute<T> name, SortDirection sortDirection)
Comparator from SortAttribute.FieldNameSortAttribute
-
-
-
-