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 23, 2016
·
1 revision
The BiFunctor interface
A BiFunctor can transform data with two type parameters representing two potential types into another two types (e.g. A Map has a type for it's Keys and Values, we could transform both, an Xor has a Primary and Secondary type only one of which is present but we can provide mapping functions for both and execute the function against the present type).
In cyclops-react it has the following methods
bimap : transforms the data using the provided transformation Function
bipeek : allows us to consume the current elements without transforming them (e.g. to print to the console)
bitrampoline : transforms the data using a trampoline for stack-less recursion