Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ITranslationSorter<T>

Type parameters

  • T

Hierarchy

  • ITranslationSorter

Callable

  • __call(a: T, b: T): number
  • Parameters

    • a: T
    • b: T

    Returns number

Index

Methods

setEntryMapper

  • Sets this translation sorter to be getting the entry with the given mapper

    Type parameters

    • T2

    Parameters

    Returns ITranslationSorter<T2>

setFallback

  • Sets a fallback sorter for when two translations are in the same position

    Parameters

    Returns this

setReverse

  • setReverse(): this
  • setReverse(reverse: boolean): this
  • Sets this sort to be reversed

    Returns this

  • Sets whether this sort should be reversed

    Parameters

    • reverse: boolean

    Returns this

setSorter

  • setSorter<A>(sorter?: SortFallback<T, A>, ...args: A): this
  • Sets a custom sorter to override the default sort functionality

    Note: When a custom sorter is used, fallbacks registered in setFallback will not be.

    Type parameters

    • A: any[]

    Parameters

    Returns this

setTranslator

  • Sets a custom translator, which takes each value to sort and makes a string from it. These strings are cached by the sorter

    Parameters

    Returns this

Generated using TypeDoc