Toolbelt v0.2.0 Toolbelt.Map

A set of tools and utilities for working on built-in Maps.

Summary

Functions

This function works like Enum.map, but produces a new map instead of a keyword list

Just like Map.map, except that nested maps within the given map will be tranversed and also transformed

Transforms the keys of the map-like structure according to the given procedure in the second argument

Iterates over all own keys and nested keys and transforms them according to the given procedure

Transforms the values of the map-like structure according to the given procedure in the second argument

Iterates over all own values and nested values and transforms them according to the given procedure

Similar to Maplike.merge_deep, but only merges on map and no keyword lists

Functions

delete(xA, xB)

See Map.delete/2.

drop(xA, xB)

See Map.drop/2.

equal?(xA, xB)

See Map.equal?/2.

fetch(xA, xB)

See Map.fetch/2.

fetch!(xA, xB)

See Map.fetch!/2.

from_struct(xA)

See Map.from_struct/1.

get(xA, xB)

See Map.get/2.

get(xA, xB, xC)

See Map.get/3.

get_and_update(xA, xB, xC)

See Map.get_and_update/3.

get_and_update!(xA, xB, xC)

See Map.get_and_update!/3.

get_lazy(xA, xB, xC)

See Map.get_lazy/3.

has_key?(xA, xB)

See Map.has_key?/2.

keys(xA)

See Map.keys/1.

map(m, fun)

This function works like Enum.map, but produces a new map instead of a keyword list.

map_deep(m, callback)

Just like Map.map, except that nested maps within the given map will be tranversed and also transformed.

map_keys(maplike, callback)

Transforms the keys of the map-like structure according to the given procedure in the second argument.

map_keys_deep(maplike, callback)

Iterates over all own keys and nested keys and transforms them according to the given procedure.

map_values(maplike, callback)

Transforms the values of the map-like structure according to the given procedure in the second argument.

map_values_deep(maplike, callback)

Iterates over all own values and nested values and transforms them according to the given procedure.

merge(xA, xB)

See Map.merge/2.

merge(xA, xB, xC)

See Map.merge/3.

merge_deep(a, b)

Similar to Maplike.merge_deep, but only merges on map and no keyword lists.

new()

See Map.new/0.

new(xA)

See Map.new/1.

new(xA, xB)

See Map.new/2.

pop(xA, xB)

See Map.pop/2.

pop(xA, xB, xC)

See Map.pop/3.

pop_lazy(xA, xB, xC)

See Map.pop_lazy/3.

put(xA, xB, xC)

See Map.put/3.

put_new(xA, xB, xC)

See Map.put_new/3.

put_new_lazy(xA, xB, xC)

See Map.put_new_lazy/3.

size(xA)

See Map.size/1.

split(xA, xB)

See Map.split/2.

take(xA, xB)

See Map.take/2.

to_list(xA)

See Map.to_list/1.

update(xA, xB, xC, xD)

See Map.update/4.

update!(xA, xB, xC)

See Map.update!/3.

values(xA)

See Map.values/1.