DA.Traversable
Daml module
DA.Traversable
Class of data structures that can be traversed from left to right, performing an action on each element.
Daml
ModuleDA.Traversable
Latest release3.5.9
Typeclasses
class (Functor t, Foldable t) => Traversable t
Functors representing data structures that can be traversed from left to right.
Methods:
mapA:Applicativef=> (a->fb) ->ta->f(tb) Map each element of a structure to an action, evaluate these actions from left to right, and collect the results.sequence:Applicativef=>t(fa) ->f(ta) Evaluate each action in the structure from left to right, and collect the results.
- instance
Ordk=>Traversable(Mapk) - instance
TraversableTextMap - instance
TraversableOptional - instance
TraversableNonEmpty - instance
Traversable(Validationerr) - instance
Traversable(Eithera) - instance
Traversable[] - instance
Traversablea
Functions
forA
forA : (Traversable t, Applicative f) => t a -> (a -> f b) -> f (t b)
forA is mapA with its arguments flipped.