potoki-core-0.12: Low-level components of "potoki"
Potoki.Core.Consume
Contents
Synopsis
newtype Consume input output Source #
Active consumer of input into output. Sort of like a reducer in Map/Reduce.
Automates the management of resources.
Constructors
An action, which executes the provided fetch in IO, while managing the resources behind the scenes.
apConcurrently :: Consume a (b -> c) -> Consume a b -> Consume a c Source #
list :: Consume input [input] Source #
sum :: Num num => Consume num num Source #
transform :: Transform input1 input2 -> Consume input2 output -> Consume input1 output Source #
Methods
left' :: Consume a b -> Consume (Either a c) (Either b c) #
right' :: Consume a b -> Consume (Either c a) (Either c b) #
dimap :: (a -> b) -> (c -> d) -> Consume b c -> Consume a d #
lmap :: (a -> b) -> Consume b c -> Consume a c #
rmap :: (b -> c) -> Consume a b -> Consume a c #
(#.) :: Coercible * c b => (b -> c) -> Consume a b -> Consume a c #
(.#) :: Coercible * b a => Consume b c -> (a -> b) -> Consume a c #
(>>=) :: Consume a a -> (a -> Consume a b) -> Consume a b #
(>>) :: Consume a a -> Consume a b -> Consume a b #
return :: a -> Consume a a #
fail :: String -> Consume a a #
fmap :: (a -> b) -> Consume input a -> Consume input b #
(<$) :: a -> Consume input b -> Consume input a #
pure :: a -> Consume a a #
(<*>) :: Consume a (a -> b) -> Consume a a -> Consume a b #
liftA2 :: (a -> b -> c) -> Consume a a -> Consume a b -> Consume a c #
(*>) :: Consume a a -> Consume a b -> Consume a b #
(<*) :: Consume a a -> Consume a b -> Consume a a #
liftIO :: IO a -> Consume a a #