Applies a closure that accumulates each element of a stream and publishes a final result upon completion.
- iOS 13.0+
- macOS 10.15+
- Mac Catalyst 13.0+
- tvOS 13.0+
- watchOS 6.0+
- Xcode 11.0+
The value the closure receives the first time it is called.
A closure that takes the previously-accumulated value and the next element from the upstream publisher to produce a new value.
A publisher that applies the closure to all received elements and produces an accumulated value when the upstream publisher finishes.