essence-of-live-coding-0.2.0.1: General purpose live coding framework

Safe HaskellSafe
LanguageHaskell2010

LiveCoding.Cell.Feedback

Synopsis

Documentation

feedback :: (Monad m, Data s) => s -> Cell m (a, s) (b, s) -> Cell m a b Source #

newtype Feedback s s' Source #

Constructors

Feedback (s, s') 
Instances
(Data s, Data s') => Data (Feedback s s') Source # 
Instance details

Defined in LiveCoding.Cell.Feedback

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Feedback s s' -> c (Feedback s s') #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (Feedback s s') #

toConstr :: Feedback s s' -> Constr #

dataTypeOf :: Feedback s s' -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c (Feedback s s')) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (Feedback s s')) #

gmapT :: (forall b. Data b => b -> b) -> Feedback s s' -> Feedback s s' #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Feedback s s' -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Feedback s s' -> r #

gmapQ :: (forall d. Data d => d -> u) -> Feedback s s' -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Feedback s s' -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Feedback s s' -> m (Feedback s s') #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Feedback s s' -> m (Feedback s s') #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Feedback s s' -> m (Feedback s s') #

delay :: (Data s, Monad m) => s -> Cell m s s Source #

sumFeedback :: (Monad m, Num a, Data a) => Cell m a a Source #

keepJust :: (Monad m, Data a) => Cell m (Maybe a) (Maybe a) Source #

keep :: (Data a, Monad m) => a -> Cell m (Maybe a) a Source #

Initialise with a value a. If the input is Nothing, keep a will output the stored indefinitely. A new value can be stored by inputting 'Maybe a'.