Wrapper around IterableIterator interface offering a set of helpers to deal with iterations in a simple way

Since 0.0.7

Type Parameters

  • T

Implements

  • IterableIterator<T>

Constructors

Methods

  • Check whether all elements of the Stream are successful for f

    WARNING: It closes the current stream

    Parameters

    • f: (v: T) => boolean

      Condition to check

    Returns boolean

    Since 0.0.1

  • Flat map all elements of the Stream using f

    WARNING: It closes the current stream

    Type Parameters

    • U

    Parameters

    • f: (v: T) => IterableIterator<U, any, any>

      Mapper function

    Returns Stream<U>

    Since 0.0.1

  • Take the nth element of the Stream of the last (if it does not exist)

    WARNING: It closes the current stream

    Parameters

    • nth: number

      Position of the element to extract

    Returns null | T

    Since 0.0.12

  • Check whether one of the elements of the Stream is successful for f

    WARNING: It closes the current stream

    Parameters

    • f: (v: T) => boolean

      Condition to check

    Returns [boolean, null | T]

    Since 0.0.1

  • Join others Stream to the current Stream

    WARNING: It closes the current stream and the other ones (as soon as it iterates over them)

    Parameters

    • ...others: IterableIterator<T, any, any>[]

      Streams to join to the current Stream

    Returns Stream<T>

    Since 0.0.1