module Data.Conduit
(
Source
, Conduit
, Sink
, ConduitM
, (.|)
, ($$)
, ($=)
, (=$)
, (=$=)
, connect
, fuse
, fuseBoth
, fuseBothMaybe
, fuseUpstream
, await
, yield
, yieldM
, leftover
, runConduit
, runConduitPure
, runConduitRes
, bracketP
, addCleanup
, yieldOr
, catchC
, handleC
, tryC
, Producer
, Consumer
, toProducer
, toConsumer
, awaitForever
, transPipe
, mapOutput
, mapOutputMaybe
, mapInput
, mergeSource
, passthroughSink
, sourceToList
, ResumableSource
, newResumableSource
, ($$+)
, ($$++)
, ($$+-)
, ($=+)
, unwrapResumable
, closeResumableSource
, ResumableConduit
, newResumableConduit
, (=$$+)
, (=$$++)
, (=$$+-)
, unwrapResumableConduit
, fuseLeftovers
, fuseReturnLeftovers
, Flush (..)
, ZipSource (..)
, sequenceSources
, ZipSink (..)
, sequenceSinks
, ZipConduit (..)
, sequenceConduits
) where
import Data.Conduit.Internal.Conduit
import Data.Void (Void)
import Data.Functor.Identity (Identity, runIdentity)
import Control.Monad.Trans.Resource (ResourceT, runResourceT)
import Control.Monad.Trans.Control (MonadBaseControl)
connect :: Monad m => Source m a -> Sink a m b -> m b
connect = ($$)
fuse :: Monad m => Conduit a m b -> ConduitM b c m r -> ConduitM a c m r
fuse = (=$=)
infixr 2 .|
(.|) :: Monad m
=> ConduitM a b m ()
-> ConduitM b c m r
-> ConduitM a c m r
(.|) = fuse
runConduitPure :: ConduitM () Void Identity r -> r
runConduitPure = runIdentity . runConduit
runConduitRes :: MonadBaseControl IO m
=> ConduitM () Void (ResourceT m) r
-> m r
runConduitRes = runResourceT . runConduit