Private
filterPrivate
matchPrivate
searchPrivate
searchChains a new rank function to the sorting algorithm. If a chained rank function returns a rank of 0 or true, the next rank functions in the chain will be ignored. Otherwise, the resulting number will be added to the rank. If the rank function returns false, a value of 1 will be added. The final sort function will order the values by the rank, with the lowest number first.
The rank function to chain.
Private
makeGenerates a MatchSort object that applies the sorting algorithm to a two-dimensional array, where the best ranking item in each list is used in the final algorithm. This can be used to sort lists of items with multiple searchable keywords.
The generated MatchSort object.
Generates a MatchSort object that applies the sorting algorithm to the given property of the values.
The key of the property that holds the value to sort by.
The generated MatchSort object.
Runs the sorting algorithm on the given values.
The search term.
The values to sort.
The sorted values.
The result is cached, so that if the search term starts with the previous search term, the previous result is used as the input to the sort function. This applies as long as the given values array is the same object.
Generated using TypeDoc
A class that allows to build and run a sorting algorithm on a list of items with type T.