Contents

init(upstream:size:prefetch:whenFull:)

Creates a publisher that buffers elements received from an upstream publisher.

Declaration

init(upstream: Upstream, size: Int, prefetch: Publishers.PrefetchStrategy, whenFull: Publishers.BufferingStrategy<Publishers.Buffer<Upstream>.Failure>)

Parameters

  • upstream:

    The publisher from which this publisher receives elements.

  • size:

    The maximum number of elements to store.

  • prefetch:

    The strategy for initially populating the buffer.

  • whenFull:

    The action to take when the buffer becomes full.