Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Output o m a where
- output :: forall o r. MemberWithError (Output o) r => o -> Sem r ()
- runOutputList :: forall o r a. Sem (Output o ': r) a -> Sem r ([o], a)
- runOutputMonoid :: forall o m r a. Monoid m => (o -> m) -> Sem (Output o ': r) a -> Sem r (m, a)
- ignoreOutput :: Sem (Output o ': r) a -> Sem r a
- runOutputBatched :: forall o r a. Member (Output [o]) r => Int -> Sem (Output o ': r) a -> Sem r a
Effect
data Output o m a where Source #
An effect capable of sending messages. Useful for streaming output and for logging.
Instances
type DefiningModule (Output :: Type -> k -> Type -> Type) Source # | |
Defined in Polysemy.Output |
Actions
Interpretations
runOutputList :: forall o r a. Sem (Output o ': r) a -> Sem r ([o], a) Source #
Run an Output
effect by transforming it into a list of its values.
Since: 1.0.0.0
runOutputMonoid :: forall o m r a. Monoid m => (o -> m) -> Sem (Output o ': r) a -> Sem r (m, a) Source #
Run an Output
effect by transforming it into a monoid.
Since: 1.0.0.0