definitive-base-1.0: The base modules of the Definitive framework.

Safe HaskellNone

Algebra.Classes

Synopsis

Documentation

class Functor f whereSource

Methods

map :: (a -> b) -> f a -> f bSource

class Applicative m => Monad m whereSource

Methods

join :: m (m a) -> m aSource

(>>=) :: m a -> (a -> m b) -> m bSource

Instances

Monad [] 
Monad IO 
Monad Maybe 
Monad Tree 
Monad Interleave 
Monad Id 
Monad TimeVal 
Monad ((->) a) 
Monad (Either a) 
Monoid w => Monad ((,) w) 
MonadFix m => Monad (Backwards m) 
Monad m => Monad (MaybeT m) 
Monad m => Monad (TreeT m) 
Monad m => Monad (ListT m) 
Ord t => Monad (Future t) 
Ord t => Monad (Event t) 
(Traversable g, Monad f, Monad g) => Monad (:.: f g) 
(Monad f, Monad g, Traversable f) => Monad (Compose' f g) 
Monad m => Monad (StateT s m) 
Monad m => Monad (ReaderT r m) 
(Monoid w, Monad m) => Monad (WriterT w m) 
Monad m => Monad (ContT r m) 
Monad m => Monad (EitherT e m) 
(Ring t, Monad m) => Monad (ProbT t m) 
(Monoid w, Monad m) => Monad (WriterAccT w acc m) 
(Monoid w, Monad m) => Monad (RWST r w s m) 

class Monad m => MonadFix m whereSource

The class of all monads that have a fixpoint

Methods

mfix :: (a -> m a) -> m aSource

Instances

MonadFix [] 
MonadFix IO 
MonadFix Id 
MonadFix ((->) b) 
MonadFix (Either e) 
MonadFix m => MonadFix (Backwards m) 
MonadFix m => MonadFix (MaybeT m) 
MonadFix m => MonadFix (TreeT m) 
MonadFix m => MonadFix (ListT m) 
(MonadFix f, Traversable g, Monad g) => MonadFix (:.: f g) 
(MonadFix g, Monad f, Traversable f) => MonadFix (Compose' f g) 
MonadFix m => MonadFix (StateT s m) 
MonadFix m => MonadFix (ReaderT r m) 
(Monoid w, MonadFix m) => MonadFix (WriterT w m) 
MonadFix m => MonadFix (EitherT e m) 
(Ring t, MonadFix m) => MonadFix (ProbT t m) 
(Monoid w, MonadFix m) => MonadFix (WriterAccT w acc m) 
(Monoid w, MonadFix m) => MonadFix (RWST r w s m) 

class MonadTrans t => ConcreteMonad t whereSource

Methods

generalize :: Monad m => t Id a -> t m aSource

class Monad m => MonadState s m | m -> s whereSource

Methods

get :: m sSource

put :: s -> m ()Source

modify :: (s -> s) -> m ()Source

Instances

MonadState s m => MonadState s (ListT m) 
Monad m => MonadState s (StateT s m) 
MonadState s m => MonadState s (ReaderT r m) 
(Monoid w, MonadState r m) => MonadState r (WriterT w m) 
(MonadState s m, Monoid w, SubSemi acc w) => MonadState s (WriterAccT w acc m) 
(Monad m, Monoid w) => MonadState s (RWST r w s m) 
MonadState (IO ()) IO 

class Monad m => MonadReader r m | m -> r whereSource

Methods

ask :: m rSource

local :: (r -> r) -> m a -> m aSource

Instances

MonadReader r ((->) r) 
MonadReader r m => MonadReader r (StateT s m) 
Monad m => MonadReader r (ReaderT r m) 
(Monoid w, MonadReader r m) => MonadReader r (WriterT w m) 
(Monad m, Monoid w) => MonadReader r (RWST r w s m) 

class (Monad m, Monoid w) => MonadWriter w m | m -> w whereSource

Methods

tell :: w -> m ()Source

listen :: m a -> m (w, a)Source

censor :: m (a, w -> w) -> m aSource

Instances

Monoid w => MonadWriter w ((,) w) 
MonadWriter w m => MonadWriter w (ListT m) 
MonadWriter w m => MonadWriter w (StateT s m) 
MonadWriter w m => MonadWriter w (ReaderT r m) 
(Monoid w, Monad m) => MonadWriter w (WriterT w m) 
(Monad m, SubSemi acc w, Monoid w) => MonadWriter w (WriterAccT w acc m) 
(Monad m, Monoid w) => MonadWriter w (RWST r w s m) 
(Ring t, Monad m) => MonadWriter (Product t) (ProbT t m) 

class (SubSemi acc w, MonadWriter w m) => MonadWriterAcc w acc m whereSource

Methods

getAcc :: m accSource

Instances

MonadWriterAcc w acc m => MonadWriterAcc w acc (StateT s m) 
MonadWriterAcc w acc m => MonadWriterAcc w acc (ReaderT r m) 
(Monad m, Monoid w, SubSemi acc w) => MonadWriterAcc w acc (WriterAccT w acc m) 

class Monad m => MonadList m whereSource

Methods

fork :: [a] -> m aSource

Instances

MonadList [] 
Monad m => MonadList (ListT m) 
MonadList m => MonadList (StateT s m) 
MonadList m => MonadList (ReaderT r m) 
(Monoid w, MonadList m) => MonadList (WriterT w m) 
(Monad m, Ring t, Fractional t) => MonadList (ProbT t m) 
(Monoid w, MonadList m) => MonadList (RWST r w s m) 

class Monad m => MonadCont m whereSource

Methods

callCC :: ((a -> m b) -> m a) -> m aSource

Instances

MonadCont m => MonadCont (StateT s m) 
MonadCont m => MonadCont (ReaderT r m) 
(Monoid w, MonadCont m) => MonadCont (WriterT w m) 
Monad m => MonadCont (ContT r m) 
(Monoid w, MonadCont m) => MonadCont (RWST r w s m) 

class Monad m => MonadError e m | m -> e whereSource

Methods

throw :: e -> m aSource

catch :: (e -> m a) -> m a -> m aSource