Type parameters

  • T

Hierarchy

Index

Constructors

constructor

  • Parameters

    • source: Iterable<T>

    Returns LinqHelper

Accessors

list

  • get list(): List<T>

Protected source

  • get source(): Iterable<T>

Methods

[Symbol.iterator]

  • [Symbol.iterator](): Generator<T, void, undefined>
  • Returns Generator<T, void, undefined>

aggregate

  • aggregate(func: function): T
  • Parameters

    • func: function
        • (av: T, e: T): T
        • Parameters

          • av: T
          • e: T

          Returns T

    Returns T

aggregate2

  • aggregate2(seed: T, func: function): T
  • Parameters

    • seed: T
    • func: function
        • (av: T, e: T): T
        • Parameters

          • av: T
          • e: T

          Returns T

    Returns T

all

  • all(predicate?: function, __this?: any): boolean
  • Parameters

    • Optional predicate: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    • Optional __this: any

    Returns boolean

any

  • any(predicate?: function, __this?: any): boolean
  • Parameters

    • Optional predicate: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    • Optional __this: any

    Returns boolean

average

  • average(selector?: function): number
  • Parameters

    • Optional selector: function
        • (value: T): number
        • Parameters

          • value: T

          Returns number

    Returns number

cast

concat

contains

  • contains(item: T): boolean

copyTo

  • copyTo(array: T[], index: number): void
  • Parameters

    • array: T[]
    • index: number

    Returns void

count2

  • count2(selector?: function, __this?: any): number
  • Parameters

    • Optional selector: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    • Optional __this: any

    Returns number

defaultIfEmpty

distinct

except

first

  • first(selector?: function, __this?: any): T
  • Parameters

    • Optional selector: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    • Optional __this: any

    Returns T

firstOrDefault

  • firstOrDefault(predicate?: function): T
  • Parameters

    • Optional predicate: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    Returns T

fullOuterJoin

  • fullOuterJoin<K, V, Z>(inner: Iterable<V>, outerKeySelector: function, innerKeySelector: function, resultSelector: function, __this?: any): LinqHelper<Z>
  • Type parameters

    • K

    • V

    • Z

    Parameters

    • inner: Iterable<V>
    • outerKeySelector: function
        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • innerKeySelector: function
        • (value: V): K
        • Parameters

          • value: V

          Returns K

    • resultSelector: function
        • (value1: T, value2: V): Z
        • Parameters

          • value1: T
          • value2: V

          Returns Z

    • Optional __this: any

    Returns LinqHelper<Z>

groupBy

groupJoin

  • groupJoin<U, K, V>(inner: Iterable<U>, outerKeySelector: function, innerKeySelector: function, resultSelector: function, __this?: any): LinqHelper<V>
  • Type parameters

    • U

    • K

    • V

    Parameters

    • inner: Iterable<U>
    • outerKeySelector: function
        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • innerKeySelector: function
        • (value: U): K
        • Parameters

          • value: U

          Returns K

    • resultSelector: function
        • (value1: T, value2: List<U>): V
        • Parameters

          • value1: T
          • value2: List<U>

          Returns V

    • Optional __this: any

    Returns LinqHelper<V>

join2

  • join2<U, K, V>(inner: Iterable<U>, outerKeySelector: function, innerKeySelector: function, resultSelector: function, __this?: any): LinqHelper<V>
  • Type parameters

    • U

    • K

    • V

    Parameters

    • inner: Iterable<U>
    • outerKeySelector: function
        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • innerKeySelector: function
        • (value: U): K
        • Parameters

          • value: U

          Returns K

    • resultSelector: function
        • (value1: T, value2: U): V
        • Parameters

          • value1: T
          • value2: U

          Returns V

    • Optional __this: any

    Returns LinqHelper<V>

lastOrDefault

  • lastOrDefault(): T

max

  • max<S>(selector?: function): S
  • Type parameters

    • S

    Parameters

    • Optional selector: function
        • (value: T): S
        • Parameters

          • value: T

          Returns S

    Returns S

min

  • min<S>(selector?: function): S
  • Type parameters

    • S

    Parameters

    • Optional selector: function
        • (value: T): S
        • Parameters

          • value: T

          Returns S

    Returns S

orderBy

  • Type parameters

    • K

    Parameters

    • keySelector: function
        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional comparer: IComparer<K>

    Returns LinqHelper<T>

orderByDescending

select

  • select<S>(selector: function, __this?: any): LinqHelper<S>
  • Type parameters

    • S

    Parameters

    • selector: function
        • (value: T): S
        • Parameters

          • value: T

          Returns S

    • Optional __this: any

    Returns LinqHelper<S>

selectMany

  • selectMany<S>(selector: function, __this?: any): LinqHelper<S>

selectMany2

  • selectMany2<C, V>(collectionSelector: function, resultSelector: function, __this?: any): LinqHelper<V>
  • Type parameters

    • C

    • V

    Parameters

    • collectionSelector: function
        • (value: T): List<C>
        • Parameters

          • value: T

          Returns List<C>

    • resultSelector: function
        • (value1: T, value2: C): V
        • Parameters

          • value1: T
          • value2: C

          Returns V

    • Optional __this: any

    Returns LinqHelper<V>

sequenceEqual

  • sequenceEqual(second: Iterable<T>): boolean

skip

sum

  • sum(selector?: function): number
  • Parameters

    • Optional selector: function
        • (value: T): number
        • Parameters

          • value: T

          Returns number

    Returns number

take

toArray

  • toArray(): T[]

toDictionary

  • toDictionary<K, V>(keySelector: function, elementSelector: function): Dictionary<K, V>
  • Type parameters

    • K

    • V

    Parameters

    • keySelector: function
        • (item: T): K
        • Parameters

          • item: T

          Returns K

    • elementSelector: function
        • (item: T): V
        • Parameters

          • item: T

          Returns V

    Returns Dictionary<K, V>

toList

toLookup

  • toLookup<K>(keySelector: function, __this?: any): Hashtable
  • Type parameters

    • K

    Parameters

    • keySelector: function
        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional __this: any

    Returns Hashtable

union

where

  • where(predicate: function, __this?: any): LinqHelper<T>
  • Parameters

    • predicate: function
        • (value: T, index: number): boolean
        • Parameters

          • value: T
          • index: number

          Returns boolean

    • Optional __this: any

    Returns LinqHelper<T>

zip

  • zip<S, R>(second: Iterable<S>, resultSelector: function): LinqHelper<R>
  • Type parameters

    • S

    • R

    Parameters

    • second: Iterable<S>
    • resultSelector: function
        • (first: T, second: S): R
        • Parameters

          • first: T
          • second: S

          Returns R

    Returns LinqHelper<R>

Static repeat

  • repeat<T>(element: T, count: number): LinqHelper<T>

Generated using TypeDoc