Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Control.Monad.Time
Synopsis
- class Monad m => MonadTime m where
- getCurrentTime :: m UTCTime
- threadDelay :: Int -> m ()
Documentation
class Monad m => MonadTime m where Source #
A class interface with overridable time implementation.
Import DefaultInstance
for the default
implementation using the real underlying time functions.
See SimulatedTime
for an instance
that allows to control time.
Instances
MonadTime IO Source # | |
Defined in Control.Monad.Time.DefaultInstance | |
(MonadTime m, MonadTrans t, Monad (t m)) => MonadTime (t m) Source # | |
Defined in Control.Monad.Time | |
MonadIO m => MonadTime (SimulatedTimeT m) Source # | |
Defined in Control.Monad.Trans.SimulatedTime Methods getCurrentTime :: SimulatedTimeT m UTCTime Source # threadDelay :: Int -> SimulatedTimeT m () Source # | |
MonadIO m => MonadTime (RealTimeT m) Source # | |
Defined in Control.Monad.Trans.SimulatedTime |