View Source Dx.Util.Map (dx v0.3.0)

Utility functions for working with Map data structures.

Link to this section Summary

Functions

When given two maps, merges the second map into the first. When the first argument is nil, returns the second argument.

Returns a Map with given keys and values zipped together

Link to this section Functions

Link to this function

do_put_in(map, field, val)

View Source
Link to this function

do_zip(map, list1, list2)

View Source

When given two maps, merges the second map into the first. When the first argument is nil, returns the second argument.

Returns a Map with given keys and values zipped together

examples

Examples

iex> [:d, :e, :b]
...> |> Dx.Util.Map.zip([8, 2, 3])
%{d: 8, e: 2, b: 3}