StrawHat.Map v0.3.1 StrawHat.Map.Address View Source
Defines functionality for addresses management.
Link to this section Summary
Functions
Create an address
Destroy an address
Get an address by id
Get an address by id
Get the list of addresses
Get list of addresses
Update an address
Link to this section Functions
Link to this function
create_address(address_attrs)
View Source
create_address(StrawHat.Map.Schema.Address.address_attrs()) :: {:ok, StrawHat.Map.Schema.Address.t()} | {:error, Ecto.Changeset.t()}
Create an address.
Link to this function
destroy_address(address)
View Source
destroy_address(StrawHat.Map.Schema.Address.t()) :: {:ok, StrawHat.Map.Schema.Address.t()} | {:error, Ecto.Changeset.t()}
Destroy an address.
Link to this function
find_address(address_id)
View Source
find_address(String.t()) :: {:ok, StrawHat.Map.Schema.Address.t()} | {:error, StrawHat.Error.t()}
Get an address by id
.
Link to this function
get_address(address_id)
View Source
get_address(String.t()) :: StrawHat.Map.Schema.Address.t() | nil | no_return()
Get an address by id
.
Link to this function
get_addresses(pagination \\ [])
View Source
get_addresses(Scrivener.Config.t()) :: Scrivener.Page.t()
Get the list of addresses.
Link to this function
get_addresses_by_ids(address_ids)
View Source
get_addresses_by_ids([integer()]) :: [StrawHat.Map.Schema.Address.t()] | no_return()
Get list of addresses.
Link to this function
update_address(address, address_attrs)
View Source
update_address( StrawHat.Map.Schema.Address.t(), StrawHat.Map.Schema.Address.address_attrs() ) :: {:ok, StrawHat.Map.Schema.Address.t()} | {:error, Ecto.Changeset.t()}
Update an address.