Options
All
  • Public
  • Public/Protected
  • All
Menu

Type parameters

  • T

Hierarchy

  • Set<T>
    • SortableSet

Index

Constructors

  • new SortableSet<T>(values?: null | readonly T[]): SortableSet<T>
  • new SortableSet<T>(iterable?: null | Iterable<T>): SortableSet<T>
  • Type parameters

    • T

    Parameters

    • Optional values: null | readonly T[]

    Returns SortableSet<T>

  • Type parameters

    • T

    Parameters

    • Optional iterable: null | Iterable<T>

    Returns SortableSet<T>

Methods

  • [iterator](): IterableIterator<T>
  • Iterates over values in the set.

    Returns IterableIterator<T>

  • Get data from cache

    Type parameters

    • R

    Parameters

    Returns R

  • getFromUnorderedCache<R>(fn: (arg0: SortableSet<T>) => R): R
  • Get data from cache (ignoring sorting)

    Type parameters

    • R

    Parameters

    Returns R

  • Returns SortableSet<T>

  • sortWith(sortFn: (arg0: T, arg1: T) => number): void
  • Sort with a comparer function

    Parameters

    • sortFn: (arg0: T, arg1: T) => number
        • (arg0: T, arg1: T): number
        • Parameters

          • arg0: T
          • arg1: T

          Returns number

    Returns void

  • toJSON(): T[]
  • Returns T[]