Type parameters

  • T

Hierarchy

Indexable

[n: number]: T

Index

Constructors

constructor

  • new ListStack(items?: T[] | number): ListStack

Properties

length

length: number

Gets or sets the length of the array. This is a number one higher than the highest index in the array.

Accessors

countItems

  • get countItems(): number

Methods

add

  • add(item: T): void
  • Parameters

    • item: T

    Returns void

addRange

  • addRange(items: List<T> | T[]): void

aggregate

  • aggregate(func: function): T
  • Applies an accumulator function over a sequence.

    Parameters

    • func: function

      An accumulator function to be invoked on each element.

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

          • av: T
          • e: T

          Returns T

    Returns T

    The final accumulator value.

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
  • Determines whether any element of a sequence satisfies a condition.

    Parameters

    • Optional predicate: function

      A function to test each element for a condition.

        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    • Optional __this: any

    Returns boolean

    true if any elements in the source sequence pass the test in the specified predicate; otherwise, false.

at

  • at(index: number): T | undefined
  • Takes an integer value and returns the item at that index, allowing for positive and negative integers. Negative integers count back from the last item in the array.

    Parameters

    • index: number

    Returns T | undefined

average

  • average(selector?: function): number
  • Computes the average of a sequence of System.Int64 values that are obtained by invoking a transform function on each element of the input sequence.

    selector

    A transform function to apply to each element. // // Type parameters: // TSource: // The type of the elements of source. //

    Parameters

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

          • value: T

          Returns number

    Returns number

    The average of the sequence of values.

cast

  • cast<S>(): List<S>
  • Converts the elements of an List to the specified type.

    Type parameters

    • S

    Returns List<S>

    An List that contains each element of the source sequence converted to the specified type.

clear

  • clear(): void
  • Removes all elements from the List.

    Returns void

concat

  • Concatenates two sequences.

    Parameters

    • second: List<T>

      The sequence to concatenate to the first sequence.

    Returns List<T>

    An List that contains the concatenated elements of the two input sequences.

contains

  • contains(item: T): boolean
  • Determines whether an element is in the List.

    Parameters

    • item: T

      The object to locate in the List. The value can be null for reference types.

    Returns boolean

    true if item is found in the List otherwise, false.

copyTo

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

    • array: any[]
    • Default value index: number = 0

    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

  • defaultIfEmpty(): List<T>

distinct

  • distinct(): List<T>
  • Returns distinct elements from a sequence by using the default equality comparer to compare values.

    Returns List<T>

    An List that contains distinct elements from the source sequence.

every

  • every<S>(predicate: function, thisArg?: any): this
  • every(predicate: function, thisArg?: any): boolean
  • Determines whether all the members of an array satisfy the specified test.

    Type parameters

    • S: T

    Parameters

    • predicate: function

      A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.

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

          • value: T
          • index: number
          • array: T[]

          Returns value

    • Optional thisArg: any

      An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

    Returns this

  • Determines whether all the members of an array satisfy the specified test.

    Parameters

    • predicate: function

      A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.

        • (value: T, index: number, array: T[]): unknown
        • Parameters

          • value: T
          • index: number
          • array: T[]

          Returns unknown

    • Optional thisArg: any

      An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

    Returns boolean

except

exists

  • exists(predicate: function): boolean
  • Parameters

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

          • value: T

          Returns boolean

    Returns boolean

filter

  • filter<S>(predicate: function, thisArg?: any): S[]
  • filter(predicate: function, thisArg?: any): T[]
  • Returns the elements of an array that meet the condition specified in a callback function.

    Type parameters

    • S: T

    Parameters

    • predicate: function

      A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.

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

          • value: T
          • index: number
          • array: T[]

          Returns value

    • Optional thisArg: any

      An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

    Returns S[]

  • Returns the elements of an array that meet the condition specified in a callback function.

    Parameters

    • predicate: function

      A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.

        • (value: T, index: number, array: T[]): unknown
        • Parameters

          • value: T
          • index: number
          • array: T[]

          Returns unknown

    • Optional thisArg: any

      An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

    Returns T[]

findIndex2

  • findIndex2(match: function): number
  • Parameters

    • match: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    Returns number

findLastIndex2

  • findLastIndex2(match: function): number
  • Parameters

    • match: function
        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    Returns number

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
  • Returns the first element of the sequence that satisfies a condition or a default value if no such element is found.

    Parameters

    • Optional predicate: function

      A function to test each element for a condition.

        • (value: T): boolean
        • Parameters

          • value: T

          Returns boolean

    Returns T

    if source is empty or if no element passes the test specified by predicate; otherwise, the first element in source that passes the test specified by predicate.

firstOrDefaultAsNullableNumber

  • firstOrDefaultAsNullableNumber(): number | null

firstOrDefaultAsNumber

  • firstOrDefaultAsNumber(): number

forEach

  • forEach(callbackfn: function, thisArg?: any): void
  • Performs the specified action for each element in an array.

    Parameters

    • callbackfn: function

      A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.

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

          • value: T
          • index: number
          • array: T[]

          Returns void

    • Optional thisArg: any

      An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.

    Returns void

fullOuterJoin

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

    • K

    • V

    • Z

    Parameters

    • inner: List<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 List<Z>

getArrayItem

  • getArrayItem(itemIndex: number): List<any[]>

getByIndex

  • getByIndex(index: number, keys?: string[]): T
  • Parameters

    • index: number
    • Default value keys: string[] = null

    Returns T

getKeys

  • getKeys(): string[]

getRange

  • getRange(index: number, count: number): List<T>
  • Parameters

    • index: number
    • count: number

    Returns List<T>

groupBy

  • groupBy<K>(keySelector: function, __this?: any): List<Grouping<K, T>>
  • Groups the elements of a sequence according to a specified key selector function and compares the keys by using a specified comparer.

    Type parameters

    • K

    Parameters

    • keySelector: function

      A function to extract the key for each element.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional __this: any

    Returns List<Grouping<K, T>>

    An IEnumerable<IGrouping<TKey, TSource>> in C# or IEnumerable(Of IGrouping(Of TKey, TSource)) in Visual Basic where each System.Linq.IGrouping`2 object contains a collection of objects and a key.

groupBy2

  • Groups the elements of a sequence according to a specified key selector function and compares the keys by using a specified comparer.

    Type parameters

    • K

    Parameters

    • keySelector: function

      A function to extract the key for each element.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional comparer: IEqualityComparer<K>

      An System.Collections.Generic.IEqualityComparer`1 to compare keys.

    • Optional __this: any

    Returns List<Grouping<K, T>>

    An IEnumerable<IGrouping<TKey, TSource>> in C# or IEnumerable(Of IGrouping(Of TKey, TSource)) in Visual Basic where each System.Linq.IGrouping`2 object contains a collection of objects and a key.

groupJoin

  • groupJoin<U, K, V>(inner: List<U>, outerKeySelector: function, innerKeySelector: function, resultSelector: function, __this?: any): List<V>
  • Correlates the elements of two sequences based on equality of keys and groups the results. The default equality comparer is used to compare keys.

    Type parameters

    • U

    • K

    • V

    Parameters

    • inner: List<U>

      The sequence to join to the first sequence.

    • outerKeySelector: function

      A function to extract the join key from each element of the first sequence.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • innerKeySelector: function

      A function to extract the join key from each element of the second sequence.

        • (value: U): K
        • Parameters

          • value: U

          Returns K

    • resultSelector: function

      A function to create a result element from an element from the first sequence and a collection of matching elements from the second sequence.

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

          • value1: T
          • value2: List<U>

          Returns V

    • Optional __this: any

    Returns List<V>

    An List that contains elements of type V that are obtained by performing a grouped join on two sequences.

indexOf

  • indexOf(searchElement: T, fromIndex?: number): number
  • Returns the index of the first occurrence of a value in an array, or -1 if it is not present.

    Parameters

    • searchElement: T

      The value to locate in the array.

    • Optional fromIndex: number

      The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.

    Returns number

insert

  • insert(index: number, item: T): void
  • Parameters

    • index: number
    • item: T

    Returns void

join

  • join(separator?: string): string
  • Adds all the elements of an array into a string, separated by the specified separator string.

    Parameters

    • Optional separator: string

      A string used to separate one element of the array from the next in the resulting string. If omitted, the array elements are separated with a comma.

    Returns string

join2

  • join2<U, K, V>(inner: List<U>, outerKeySelector: function, innerKeySelector: function, resultSelector: function, __this?: any): List<V>
  • Correlates the elements of two sequences based on matching keys. The default equality comparer is used to compare keys.

    Type parameters

    • U

    • K

    • V

    Parameters

    • inner: List<U>

      The sequence to join to the first sequence.

    • outerKeySelector: function

      A function to extract the join key from each element of the first sequence.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • innerKeySelector: function

      A function to extract the join key from each element of the second sequence.

        • (value: U): K
        • Parameters

          • value: U

          Returns K

    • resultSelector: function

      A function to create a result element from two matching elements.

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

          • value1: T
          • value2: U

          Returns V

    • Optional __this: any

    Returns List<V>

    An List that has elements of type V that are obtained by performing an inner join on two sequences.

last

  • last(): T

lastIndexOf

  • lastIndexOf(searchElement: T, fromIndex?: number): number
  • Returns the index of the last occurrence of a specified value in an array, or -1 if it is not present.

    Parameters

    • searchElement: T

      The value to locate in the array.

    • Optional fromIndex: number

      The array index at which to begin searching backward. If fromIndex is omitted, the search starts at the last index in the array.

    Returns number

lastOrDefault

  • lastOrDefault(): T

map

  • map<U>(callbackfn: function, thisArg?: any): U[]
  • Calls a defined callback function on each element of an array, and returns an array that contains the results.

    Type parameters

    • U

    Parameters

    • callbackfn: function

      A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.

        • (value: T, index: number, array: T[]): U
        • Parameters

          • value: T
          • index: number
          • array: T[]

          Returns U

    • Optional thisArg: any

      An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.

    Returns U[]

max

  • max<S>(selector?: function): S
  • Invokes a transform function on each element of a sequence and returns the maximum value.

    Type parameters

    • S

    Parameters

    • Optional selector: function

      A transform function to apply to each element.

        • (value: T): S
        • Parameters

          • value: T

          Returns S

    Returns S

    The maximum value in the sequence.

min

  • min<S>(selector?: function): S
  • Invokes a transform function on each element of a sequence and returns the minimum value.

    parm

    selector A transform function to apply to each element.

    Type parameters

    • S

    Parameters

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

          • value: T

          Returns S

    Returns S

    The minimum value in the sequence.

orderBy

  • orderBy<K>(keySelector: function, comparer?: IComparer<K>): List<T>
  • Sorts the elements of a sequence in ascending order according to a key or by using a specified comparer.

    Type parameters

    • K

    Parameters

    • keySelector: function

      A function to extract a key from an element.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional comparer: IComparer<K>

      An System.Collections.Generic.IComparer`1 to compare keys.

    Returns List<T>

    An System.Linq.IOrderedEnumerable`1 whose elements are sorted according to a key.

orderByDescending

  • orderByDescending<K>(keySelector: function, comparer?: IComparer<K>): List<T>
  • Type parameters

    • K

    Parameters

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

          • value: T

          Returns K

    • Optional comparer: IComparer<K>

    Returns List<T>

peek

  • peek(depth?: number): T
  • Parameters

    • Default value depth: number = 0

    Returns T

pop

  • pop(): T

push

  • push(...items: T[]): number
  • Appends new elements to the end of an array, and returns the new length of the array.

    Parameters

    • Rest ...items: T[]

      New elements to add to the array.

    Returns number

reduce

  • reduce(callbackfn: function): T
  • reduce(callbackfn: function, initialValue: T): T
  • reduce<U>(callbackfn: function, initialValue: U): U
  • Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

    Parameters

    • callbackfn: function

      A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.

        • (previousValue: T, currentValue: T, currentIndex: number, array: T[]): T
        • Parameters

          • previousValue: T
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns T

    Returns T

  • Parameters

    • callbackfn: function
        • (previousValue: T, currentValue: T, currentIndex: number, array: T[]): T
        • Parameters

          • previousValue: T
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns T

    • initialValue: T

    Returns T

  • Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

    Type parameters

    • U

    Parameters

    • callbackfn: function

      A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.

        • (previousValue: U, currentValue: T, currentIndex: number, array: T[]): U
        • Parameters

          • previousValue: U
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns U

    • initialValue: U

      If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.

    Returns U

reduceRight

  • reduceRight(callbackfn: function): T
  • reduceRight(callbackfn: function, initialValue: T): T
  • reduceRight<U>(callbackfn: function, initialValue: U): U
  • Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

    Parameters

    • callbackfn: function

      A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.

        • (previousValue: T, currentValue: T, currentIndex: number, array: T[]): T
        • Parameters

          • previousValue: T
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns T

    Returns T

  • Parameters

    • callbackfn: function
        • (previousValue: T, currentValue: T, currentIndex: number, array: T[]): T
        • Parameters

          • previousValue: T
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns T

    • initialValue: T

    Returns T

  • Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

    Type parameters

    • U

    Parameters

    • callbackfn: function

      A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.

        • (previousValue: U, currentValue: T, currentIndex: number, array: T[]): U
        • Parameters

          • previousValue: U
          • currentValue: T
          • currentIndex: number
          • array: T[]

          Returns U

    • initialValue: U

      If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.

    Returns U

remove

  • remove(item: T): void
  • Parameters

    • item: T

    Returns void

removeAt

  • removeAt(index: number): void
  • Removes the element at the specified index of the Lis.

    throw

    index is less than 0. -or- index is equal to or greater than Count.

    Parameters

    • index: number

      The zero-based index of the element to remove.

    Returns void

removeByIndex

  • removeByIndex(index: number): List<T>

removeRange

  • removeRange(index: number, count: number): void
  • Parameters

    • index: number
    • count: number

    Returns void

reverse

  • reverse(): T[]
  • Reverses the elements in an array in place. This method mutates the array and returns a reference to the same array.

    Returns T[]

select

  • select<S>(selector: function, __this?: any): List<S>
  • Projects each element of a sequence into a new form.

    Type parameters

    • S

    Parameters

    • selector: function

      A transform function to apply to each element.

        • (value: T): S
        • Parameters

          • value: T

          Returns S

    • Optional __this: any

    Returns List<S>

    An List whose elements are the result of invoking the transform function on each element of source.

selectAsync

  • selectAsync<S>(selector: function, __this?: any): Promise<List<S>>
  • Type parameters

    • S

    Parameters

    • selector: function
        • (value: T): Promise<S>
        • Parameters

          • value: T

          Returns Promise<S>

    • Optional __this: any

    Returns Promise<List<S>>

selectMany

  • selectMany<S>(selector: function, __this?: any): List<S>
  • Type parameters

    • S

    Parameters

    • selector: function
        • (value: T): List<S>
        • Parameters

          • value: T

          Returns List<S>

    • Optional __this: any

    Returns List<S>

selectMany2

  • selectMany2<C, V>(collectionSelector: function, resultSelector: function, __this?: any): List<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 List<V>

sequenceEqual

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

setByIndex

  • setByIndex(index: number, item: T, keys?: string[]): void
  • Parameters

    • index: number
    • item: T
    • Default value keys: string[] = null

    Returns void

shift

  • shift(): T | undefined
  • Removes the first element from an array and returns it. If the array is empty, undefined is returned and the array is not modified.

    Returns T | undefined

skip

  • skip(count: number): List<T>
  • Parameters

    • count: number

    Returns List<T>

slice

  • slice(start?: number, end?: number): T[]
  • Returns a copy of a section of an array. For both start and end, a negative index can be used to indicate an offset from the end of the array. For example, -2 refers to the second to last element of the array.

    Parameters

    • Optional start: number

      The beginning index of the specified portion of the array. If start is undefined, then the slice begins at index 0.

    • Optional end: number

      The end index of the specified portion of the array. This is exclusive of the element at the index 'end'. If end is undefined, then the slice extends to the end of the array.

    Returns T[]

some

  • some(predicate: function, thisArg?: any): boolean
  • Determines whether the specified callback function returns true for any element of an array.

    Parameters

    • predicate: function

      A function that accepts up to three arguments. The some method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value true, or until the end of the array.

        • (value: T, index: number, array: T[]): unknown
        • Parameters

          • value: T
          • index: number
          • array: T[]

          Returns unknown

    • Optional thisArg: any

      An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

    Returns boolean

sort

  • sort(compareFn?: function): this
  • Sorts an array in place. This method mutates the array and returns a reference to the same array.

    Parameters

    • Optional compareFn: function

      Function used to determine the order of the elements. It is expected to return a negative value if the first argument is less than the second argument, zero if they're equal, and a positive value otherwise. If omitted, the elements are sorted in ascending, ASCII character order.

      [11,2,22,1].sort((a, b) => a - b)
      
        • (a: T, b: T): number
        • Parameters

          • a: T
          • b: T

          Returns number

    Returns this

sort2

  • sort2(): void

splice

  • splice(start: number, deleteCount?: number): T[]
  • splice(start: number, deleteCount: number, ...items: T[]): T[]
  • Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.

    Parameters

    • start: number

      The zero-based location in the array from which to start removing elements.

    • Optional deleteCount: number

      The number of elements to remove.

    Returns T[]

    An array containing the elements that were deleted.

  • Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.

    Parameters

    • start: number

      The zero-based location in the array from which to start removing elements.

    • deleteCount: number

      The number of elements to remove.

    • Rest ...items: T[]

      Elements to insert into the array in place of the deleted elements.

    Returns T[]

    An array containing the elements that were deleted.

sum

  • sum(selector?: function): number
  • Computes the sum of the sequence of System.Decimal values that are obtained by invoking a transform function on each element of the input sequence.

    Parameters

    • Optional selector: function

      A transform function to apply to each element.

        • (value: T): number
        • Parameters

          • value: T

          Returns number

    Returns number

    The sum of the projected values.

take

  • take(count: number): List<T>
  • Parameters

    • count: number

    Returns List<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

toLocaleString

  • toLocaleString(): string
  • Returns a string representation of an array. The elements are converted to string using their toLocaleString methods.

    Returns string

toLookup

  • toLookup<K>(keySelector: function, __this?: any): Hashtable
  • Creates a Lookup from an List according to a specified key selector function.

    Type parameters

    • K

    Parameters

    • keySelector: function

      A function to extract a key from each element.

        • (value: T): K
        • Parameters

          • value: T

          Returns K

    • Optional __this: any

    Returns Hashtable

    A Lookup that contains keys and values.

toString

  • toString(): string
  • Returns a string representation of an array.

    Returns string

tryCastToBool

  • tryCastToBool(): List<boolean | null>

tryCastToDateTime

tryCastToNullableDateTime

tryCastToNullableNumber

  • tryCastToNullableNumber(): List<number | null>

tryCastToNullableTimeSpan

tryCastToNumber

  • tryCastToNumber(): List<number | null>

tryCastToString

  • tryCastToString(): List<string>

tryCastToTimeSpan

tryCastValueOrFirstDefaultToNullableNumber

  • tryCastValueOrFirstDefaultToNullableNumber(): List<number | null>

tryPeek

  • tryPeek(ref: object): boolean
  • Parameters

    • ref: object
      • item: T

    Returns boolean

tryPeek2

  • tryPeek2(depth: number, ref: object): boolean
  • Parameters

    • depth: number
    • ref: object
      • item: T

    Returns boolean

tryPop

  • tryPop(ref: object): boolean
  • Parameters

    • ref: object
      • item: T

    Returns boolean

union

unshift

  • unshift(...items: T[]): number
  • Inserts new elements at the start of an array, and returns the new length of the array.

    Parameters

    • Rest ...items: T[]

      Elements to insert at the start of the array.

    Returns number

where

  • where(predicate: function, __this?: any): List<T>
  • Filters a sequence of values based on a predicate.

    Parameters

    • predicate: function

      A function to test each element for a condition.

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

          • value: T
          • index: number

          Returns boolean

    • Optional __this: any

    Returns List<T>

    An List that contains elements from the input sequence that satisfy the condition.

whereArrayItemEqualsTo

  • whereArrayItemEqualsTo(itemIndex: number, value: any): List<any[]>

whereArrayItemStringEqualsTo

  • whereArrayItemStringEqualsTo(itemIndex: number, value: string): List<any[]>

whereAsync

  • whereAsync(predicate: function, __this?: any): Promise<List<T>>
  • Parameters

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

          • value: T
          • index: number

          Returns Promise<boolean>

    • Optional __this: any

    Returns Promise<List<T>>

whereEqualsTo

  • whereEqualsTo(values1: any, values2: any): List<any[]>

whereFirstOrDefaultArrayItemStringEqualsTo

  • whereFirstOrDefaultArrayItemStringEqualsTo(itemIndex: number, value: string): any[]

zip

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

    • S

    • R

    Parameters

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

          • first: T
          • second: S

          Returns R

    Returns List<R>

Static add2

  • add2(a: any, b: any): List<any>
  • Parameters

    • a: any
    • b: any

    Returns List<any>

Static bitwiseAnd

  • bitwiseAnd(a: any, b: any): List<any>

Static bitwiseOr

  • bitwiseOr(a: any, b: any): List<any>

Static bitwiseXOr

  • bitwiseXOr(a: any, b: any): List<any>

Static create

  • create<T>(t: Type, ...values: any[]): List<T>
  • Type parameters

    • T

    Parameters

    • t: Type
    • Rest ...values: any[]

    Returns List<T>

Static div

  • div(a: any, b: any): List<any>
  • Parameters

    • a: any
    • b: any

    Returns List<any>

Static getValueOrFirstOrDefault

  • getValueOrFirstOrDefault(value: any): any

Static mult

  • mult(a: any, b: any): List<any>
  • Parameters

    • a: any
    • b: any

    Returns List<any>

Static repeat

  • repeat<T>(element: T, count: number): List<T>
  • Type parameters

    • T

    Parameters

    • element: T
    • count: number

    Returns List<T>

Static sub

  • sub(a: any, b: any): List<any>
  • Parameters

    • a: any
    • b: any

    Returns List<any>

Static toString2

  • toString2(value: any): string
  • Parameters

    • value: any

    Returns string

Generated using TypeDoc