| Safe Haskell | None |
|---|
Data.Conduit.Util
Contents
Description
Various utility functions versions of conduit.
Misc
zipSources :: Monad m => Source m a -> Source m b -> Source m (a, b)Source
Combines two sources. The new source will stop producing once either source has been exhausted.
Since 1.0.13
zipSinks :: Monad m => Sink i m r -> Sink i m r' -> Sink i m (r, r')Source
Combines two sinks. The new sink will complete when both input sinks have completed.
Any leftovers are discarded.
Since 0.4.1
Turn a Sink into a Conduit in the following way:
- All input passed to the
Sinkis yielded downstream. - When the
Sinkfinishes processing, the result is passed to the provided to the finalizer function.
Note that the Sink will stop receiving input as soon as the downstream it
is connected to shuts down.
An example usage would be to write the result of a Sink to some mutable
variable while allowing other processing to continue.
Since 1.0.10