Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "from/iterable"

Index

Functions

Const fromIterable

  • Returns a Stream of values from provided iterable, emitted at the given delay interval.

    remarks

    Asynchronously starts pulling values from source iterable when the first subscriber becomes available. The values are processed & emitted via setInterval(), using the given delay value (default: 0). By default, once the iterable is exhausted (if finite), calls ISubscriber.done to close the stream, but this can be re-configured via provided options.

    Type parameters

    • T

    Parameters

    Returns Stream<T>

Const fromIterableSync

  • Creates a new Stream of given iterable which synchronously calls .next() for each item of the iterable when the first (and in this case the only one) subscriber becomes available. Once the iterable is exhausted (MUST be finite!), then calls .done() by default, but can be avoided by passing false as last argument.

    Type parameters

    • T

    Parameters

    • src: Iterable<T>

      -

    • Optional opts: Partial<CommonOpts>

      -

    Returns Stream<T>

Generated using TypeDoc