SortOptionDsl
DSL to describe a sort order.
This DSL declares the methods ascending and descending which describe in which order elements are sorted.
For example,
ascending(User::name)
descending(User::age)
Content copied to clipboard
will sort users in alphabetical order of their name, and when users have the same name, will sort them in decreasing order of their age.
See WithSort.sort.
Properties
Functions
Link copied to clipboard
If two documents have a different value of field, the one with greater value will be returned first.
Link copied to clipboard
open operator fun <Root, Type> KProperty1<Root, Collection<Type>>.get(index: Int): Field<Root, Type>
Refers to a specific item in an array, by its index.
open operator fun <Root, Type> KProperty1<Root, Map<String, Type>>.get(index: String): Field<Root, Type>
Refers to a specific item in a map, by its name.
Link copied to clipboard
Writes the result of simplifying to a new Bson.
Link copied to clipboard
Writes the result of simplifying this expression into writer.