-
- All Implemented Interfaces:
-
io.getstream.chat.android.client.api.models.querysort.QuerySorter
@Deprecated(message = Use QuerySortByReflection., replaceWith = @ReplaceWith(imports = {}, expression = QuerySortByReflection), level = DeprecationLevel.ERROR) public final class QuerySort<T extends Object> extends QuerySortByReflection<T>
Sort specification for api queries. You can specify QuerySort by referencing kotlin class property or passing field name as string instance. QuerySort.asc(Channel::memberCount) and QuerySort.asc<Channel>("member_count") mean the same.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classQuerySort.Companion
-
Field Summary
Fields Modifier and Type Field Description private final Comparator<in T>comparator
-
Constructor Summary
Constructors Constructor Description QuerySort()
-
Method Summary
Modifier and Type Method Description Comparator<in T>getComparator()QuerySort<T>asc(KProperty1<T, Comparable<?>> field)Creates a QuerySortByReflection with ASC as SortDirection QuerySort<T>asc(String fieldName, Class<T> javaClass)Creates a QuerySortByReflection with ASC as SortDirection QuerySort<T>asc(String fieldName)Creates a QuerySortByReflection with ASC as SortDirection QuerySort<T>asc(String fieldName, KClass<T> kClass)Creates a QuerySortByReflection with ASC as SortDirection QuerySort<T>desc(KProperty1<T, Comparable<?>> field)Creates a QuerySortByReflection with DESC as SortDirection QuerySort<T>desc(String fieldName, Class<T> javaClass)Creates a QuerySortByReflection with DESC as SortDirection QuerySort<T>desc(String fieldName)Creates a QuerySortByReflection with DESC as SortDirection QuerySort<T>desc(String fieldName, KClass<T> kClass)Creates a QuerySortByReflection with DESC as SortDirection -
Methods inherited from class io.getstream.chat.android.client.api.models.QuerySort
comparatorFromFieldSort, comparatorFromNameAttribute -
Methods inherited from class io.getstream.chat.android.client.api.models.querysort.QuerySortByReflection
equals, hashCode, toDto, toString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getComparator
Comparator<in T> getComparator()
-
asc
QuerySort<T> asc(KProperty1<T, Comparable<?>> field)
Creates a QuerySortByReflection with ASC as SortDirection
-
asc
QuerySort<T> asc(String fieldName, Class<T> javaClass)
Creates a QuerySortByReflection with ASC as SortDirection
-
asc
QuerySort<T> asc(String fieldName)
Creates a QuerySortByReflection with ASC as SortDirection
-
asc
QuerySort<T> asc(String fieldName, KClass<T> kClass)
Creates a QuerySortByReflection with ASC as SortDirection
-
desc
QuerySort<T> desc(KProperty1<T, Comparable<?>> field)
Creates a QuerySortByReflection with DESC as SortDirection
-
desc
QuerySort<T> desc(String fieldName, Class<T> javaClass)
Creates a QuerySortByReflection with DESC as SortDirection
-
desc
QuerySort<T> desc(String fieldName)
Creates a QuerySortByReflection with DESC as SortDirection
-
-
-
-