|
Advance a chain value by one step, providing 'e'.
-
c
:
'e -> Chain<'e, 'a>
-
e
:
'e
-
world
:
World
-
Returns:
Either<('e -> Chain<'e, 'a>), 'a>
|
|
Functor map for the chain monad.
-
c
:
Chain<'a, ('b -> 'c)>
-
a
:
Chain<'a, 'b>
-
Returns:
Chain<'a, 'c>
|
|
Monadic bind for the chain monad.
-
c
:
Chain<'a, 'b>
-
a
:
'b -> Chain<'a, 'c>
-
Returns:
Chain<'a, 'c>
|
|
Loop in a chain context while 'pred' evaluates to true considering only the world state.
-
pred
:
World -> bool
-
c
:
Chain<'e, unit>
-
Returns:
Chain<'e, unit>
|
|
-
Returns:
Chain<'e, World>
|
|
Get the world as transformed via 'by'.
-
by
:
World -> 'a
-
Returns:
Chain<'e, 'a>
|
|
Loop in a chain context while 'pred' evaluate to true considering only the loop data.
-
i
:
'i
-
step
:
'i -> 'i
-
pred
:
'i -> World -> bool
-
c
:
'i -> Chain<'e, unit>
-
Returns:
Chain<'e, unit>
|
|
Functor map for the chain monad.
-
f
:
'a -> 'b
-
a
:
Chain<'c, 'a>
-
Returns:
Chain<'c, 'b>
|
|
-
Returns:
Chain<'e, 'e>
|
|
Pass over the next event.
-
Returns:
Chain<'e, unit>
|
|
React to the next event, discarding the event's value.
-
expr
:
World -> unit
-
Returns:
Chain<'e, unit>
|
|
React to the next event, using the event's data in the reaction.
-
expr
:
'a -> World -> unit
-
Returns:
Chain<Event<'a, 's>, unit>
|
|
React to the next event, using the event's value in the reaction.
-
expr
:
'e -> World -> unit
-
Returns:
Chain<'e, unit>
|
|
Monadic return for the chain monad.
-
a
:
'a
-
Returns:
Chain<'b, 'a>
|
|
-
c
:
Chain<'e, 'a>
-
world
:
World
-
Returns:
Either<('e -> Chain<'e, 'a>), 'a>
|
|
-
expr
:
World -> unit
-
Returns:
Chain<'e, unit>
|
|
Update the world with an additional transformed world parameter.
-
by
:
World -> 'a
-
expr
:
'a -> World -> unit
-
Returns:
Chain<'e, unit>
|