Safe Haskell | None |
---|---|
Language | Haskell2010 |
Servant.Server.Internal.DelayedIO
Synopsis
-
newtype
DelayedIO
a =
DelayedIO
{
- runDelayedIO' :: ReaderT Request ( ResourceT ( RouteResultT IO )) a
- liftRouteResult :: RouteResult a -> DelayedIO a
- runDelayedIO :: DelayedIO a -> Request -> ResourceT IO ( RouteResult a)
- delayedFail :: ServerError -> DelayedIO a
- delayedFailFatal :: ServerError -> DelayedIO a
- withRequest :: ( Request -> DelayedIO a) -> DelayedIO a
Documentation
Computations used in a
Delayed
can depend on the
incoming
Request
, may perform
IO
, and result in a
RouteResult
, meaning they can either succeed, fail
(with the possibility to recover), or fail fatally.
Constructors
DelayedIO | |
Fields
|
Instances
liftRouteResult :: RouteResult a -> DelayedIO a Source #
runDelayedIO :: DelayedIO a -> Request -> ResourceT IO ( RouteResult a) Source #
delayedFail :: ServerError -> DelayedIO a Source #
Fail with the option to recover.
delayedFailFatal :: ServerError -> DelayedIO a Source #
Fail fatally, i.e., without any option to recover.