Packages

Traverse and map values of deeply nested data structures: Provides a `map_deeply/2` function for Maps and Lists and Keyword Lists

Current section

Files

Jump to
data_leaf_walker lib deeply_enumerable.ex
Raw

lib/deeply_enumerable.ex

defprotocol DeeplyEnumerable do
@derive Enumerable
def map_deeply( data, fn_transform )
end
defimpl DeeplyEnumerable, for: Map do
def map_deeply( map, fn_transform ) do
DataLeafWalker.map( map, fn_transform )
end
end
defimpl DeeplyEnumerable, for: List do
def map_deeply( list, fn_transform ) do
DataLeafWalker.map( list, fn_transform )
end
end