Struct representing DDD information from BrasilAPI DDD v1.
This struct contains DDD information including the state and list of cities that use the specified area code.
Summary
Functions
Creates a DDD Info struct from a map.
Types
Functions
Creates a DDD Info struct from a map.
Examples
iex> map = %{
...> "state" => "SP",
...> "cities" => [
...> "EMBU",
...> "VÁRZEA PAULISTA",
...> "VARGEM GRANDE PAULISTA",
...> "SÃO PAULO"
...> ]
...> }
iex> Brasilapi.Ddd.Info.from_map(map)
%Brasilapi.Ddd.Info{
state: "SP",
cities: ["EMBU", "VÁRZEA PAULISTA", "VARGEM GRANDE PAULISTA", "SÃO PAULO"]
}