ContentsIndex
Org.Org.Semantic.HBase.Category.StateMonad
Synopsis
newtype StateMonad m state a = MkStateMonad {
unStateMonad :: (state -> m (state, a))
}
getState :: Monad m => StateMonad m state state
setState :: Monad m => state -> StateMonad m state ()
swapState :: Monad m => state -> StateMonad m state state
getStatePart :: Monad m => Part m state v -> StateMonad m state v
setStatePart :: Monad m => Part m state v -> v -> StateMonad m state ()
stateRef :: Monad m => Ref (StateMonad m state) state
statePartRef :: Monad m => Part m state v -> Ref (StateMonad m state) v
doState :: Monad m => state -> StateMonad m state a -> m (state, a)
runState :: Monad m => state -> StateMonad m state a -> m a
crossState :: Monad m => StateMonad m state1 a1 -> StateMonad m state2 a2 -> StateMonad m (state1, state2) (a1, a2)
Documentation
newtype StateMonad m state a
state-changing monad
Constructors
MkStateMonad
unStateMonad :: (state -> m (state, a))
Instances
HasReturn m => HasReturn (StateMonad m state)
Monad m => Functor (StateMonad m state)
Monad m => FunctorApply (StateMonad m state)
Monad m => Monad (StateMonad m state)
MonadThrow ex m => MonadThrow ex (StateMonad m state)
MonadException ex m => MonadException ex (StateMonad m state)
MonadZero m => MonadZero (StateMonad m state)
MonadOr m => MonadOr (StateMonad m state)
MonadPlus m => MonadPlus (StateMonad m state)
MonadFirst m => MonadFirst (StateMonad m state)
Monad m => LiftedMonad m (StateMonad m state)
(Monad m, RDFLiteral ex a) => AssertionMonad ex a (StateMonad m (Integer, [RDFAssertion a]))
getState :: Monad m => StateMonad m state state
setState :: Monad m => state -> StateMonad m state ()
swapState :: Monad m => state -> StateMonad m state state
getStatePart :: Monad m => Part m state v -> StateMonad m state v
setStatePart :: Monad m => Part m state v -> v -> StateMonad m state ()
stateRef :: Monad m => Ref (StateMonad m state) state
statePartRef :: Monad m => Part m state v -> Ref (StateMonad m state) v
doState :: Monad m => state -> StateMonad m state a -> m (state, a)
runState :: Monad m => state -> StateMonad m state a -> m a
crossState :: Monad m => StateMonad m state1 a1 -> StateMonad m state2 a2 -> StateMonad m (state1, state2) (a1, a2)
Produced by Haddock version 0.6