map_array v0.1.0 MapArray

Documentation for MapArray.

Link to this section Summary

Link to this section Types

Link to this type

mapper1()
mapper1() :: (any() -> any())

Link to this type

mapper2()
mapper2() :: (any(), index() -> any())

Link to this type

reducer2()
reducer2() :: (any(), any() -> any())

Link to this type

reducer3()
reducer3() :: (any(), any(), index() -> any())

Link to this type

t()
t() :: %{optional(non_neg_integer()) => any()}

Link to this section Functions

Link to this function

append(map, item)
append(t(), any()) :: t()

Link to this macro

is_index(i) (macro)

Link to this function

map(map, mapper)
map(map(), mapper1() | mapper2()) :: [any()]

Link to this function

max_index(map)
max_index(t()) :: non_neg_integer()

Link to this function

new(enumerable)
new(Enumerable.t()) :: t()

Link to this function

prepend(map, item)
prepend(t(), any()) :: t()

This is an expensive operation as it forces reconstruction of the entire map.

Link to this function

reduce(map, initial_state, reducer)
reduce(t(), any(), reducer2() | reducer3()) :: any()

Link to this function

reverse_map(map, mapper)
reverse_map(map(), (any() -> any())) :: [any()]

Link to this function

reverse_reduce(map, initial_state, reducer)
reverse_reduce(t(), any(), reducer2() | reducer3()) :: any()

Link to this function

seek_down(map, start \\ nil, finder)
seek_down(map(), nil | non_neg_integer(), (any() -> boolean())) ::
  {:ok, any()} | :error

Link to this function

seek_index_down(map, start \\ nil, finder)
seek_index_down(map(), nil | non_neg_integer(), (any() -> boolean())) ::
  {:ok, index()} | :error

Link to this function

seek_index_up(map, start \\ 0, finder)
seek_index_up(map(), nil | non_neg_integer(), (any() -> boolean())) ::
  {:ok, index()} | :error

Link to this function

seek_up(map, start \\ 0, finder)
seek_up(map(), non_neg_integer(), (any() -> boolean())) ::
  {:ok, any()} | :error

Link to this function

slice(map, arg)
slice(any(), Range.t()) :: [any()]

Link to this function

to_list(map)
to_list(map()) :: [any()]

Link to this function

to_reversed_list(map)
to_reversed_list(map()) :: [any()]