-- | Program stateful abstract fudgets in a monadic style
module ReactiveF(reactiveF,reactiveSP,module ReactionM) where
import Fudgets
import ReactionM

reactiveF :: (a -> ReactionM t b a2) -> t -> F a b
reactiveF  = forall {t} {a} {b}. (t -> a -> (t, [b])) -> t -> F a b
mapstateF  forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall {t} {a1} {o} {a2}.
(t -> ReactionM a1 o a2) -> a1 -> t -> (a1, [o])
mf
reactiveSP :: (a -> ReactionM t b a2) -> t -> SP a b
reactiveSP = forall {t} {a} {b}. (t -> a -> (t, [b])) -> t -> SP a b
mapstateSP forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall {t} {a1} {o} {a2}.
(t -> ReactionM a1 o a2) -> a1 -> t -> (a1, [o])
mf

mf :: (t -> ReactionM a1 o a2) -> a1 -> t -> (a1, [o])
mf t -> ReactionM a1 o a2
rM a1
s t
m = forall {a1} {o} {a2}. ReactionM a1 o a2 -> a1 -> (a1, [o])
react (t -> ReactionM a1 o a2
rM t
m) a1
s