You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
johnmcclean-aol edited this page Nov 22, 2016
·
2 revisions
The MonadicValue interface
A MonadicValue represents a Value that is also a monad. It has two sub-interfaces MonadicValue1 and MonadicValue2 which define flatMap methods for Monads with 1 type parameter and 2 type parameters respectively.
In cyclops-react it has the following methods
map : allows users to visit present and null states
anyM : convert this MonadicValue to an AnyM
unit : create a new instance of this MonadicValue type
nest : cojoin, nest this MonadicValue inside an instance of the same type
coflatMap : transform this MonadicValue with a user supplied function that takes this MonadicValue as an input parameter and returns a new value which will be wrapped inside a new instance of a MonadicValue of the same type