Class ReadOnlyIterableCollectionBase<T>Abstract

Base class for implementing finite read-only iterables.

Type Parameters

  • T

Hierarchy

Constructors

Methods

  • Copies all values to a numerically indexable object.

    Returns

    Type Parameters

    • TTarget extends ArrayLikeWritable<T, TTarget>

    Parameters

    • target: TTarget
    • index: number = 0

    Returns TTarget

  • Applies a reducer function to all the elements in this sequence. The first entry is used as the initial accumulator value, and the specified function is used to select the result value.

    Throws

    If the sequence is empty.

    Returns

    Type Parameters

    • T

    Parameters

    • reduction: ((previous: T, current: T, index: number) => T)
        • (previous: T, current: T, index: number): T
        • Parameters

          • previous: T
          • current: T
          • index: number

          Returns T

    Returns T

  • Applies a reducer function to all the elements in this sequence. The specified seed value is used as the initial accumulator value, and the specified function is used to select the result value.

    Returns

    Type Parameters

    • T

    • U

    Parameters

    • reduction: ((previous: U, current: T, index: number) => U)
        • (previous: U, current: T, index: number): U
        • Parameters

          • previous: U
          • current: T
          • index: number

          Returns U

    • initialValue: U

    Returns U

Generated using TypeDoc