• Creates a buffer with a view over the source sequence, causing a specified number of iterators to obtain access to all of the sequence's elements without causing multiple enumerations over the source.

    Type Parameters

    • TSource

      Source sequence element type.

    Parameters

    • Optional readerCount: number

      Number of iterators that can access the underlying buffer. Once every iterator has obtained an element from the buffer, the element is removed from the buffer.

    Returns OperatorAsyncFunction<TSource, TSource>

    Buffer enabling a specified number of iterators to retrieve all elements from the shared source sequence, without duplicating source iteration side-effects.

  • Memoizes the source sequence within a selector function where a specified number of iterators can get access to all of the sequence's elements without causing multiple iterations over the source.

    Type Parameters

    • TSource

      Source sequence element type.

    • TResult

      Result sequence element type.

    Parameters

    • Optional readerCount: number

      Number of iterators that can access the underlying buffer. Once every iterator has obtained an element from the buffer, the element is removed from the buffer.

    • Optional selector: ((value) => AsyncIterable<TResult>)

      Selector function with memoized access to the source sequence for a specified number of iterators.

        • (value): AsyncIterable<TResult>
        • Parameters

          • value: AsyncIterable<TSource>

          Returns AsyncIterable<TResult>

    Returns OperatorAsyncFunction<TSource, TResult>

    Sequence resulting from applying the selector function to the memoized view over the source sequence.

Generated using TypeDoc