A.OrdMap.fetch
You're seeing just the function
fetch
, go back to A.OrdMap module for more information.
Specs
Fetches the value for a specific key
and returns it in a ok-entry.
If the key does not exist, returns :error.
Examples
iex> ord_map = A.OrdMap.new(a: "A", b: "B", c: "C")
iex> A.OrdMap.fetch(ord_map, :c)
{:ok, "C"}
iex> A.OrdMap.fetch(ord_map, :z)
:error