View Source Mahaul.Constants (Mahaul v0.5.0)
Common constants and types.
Link to this section Summary
Types
The configuration options type.
The common error type.
The type representing a normalized environment variable value.
The type representing list of all normalized environment variable values.
The common success type.
The supported environment variable value type.
The supported environment variable type.
Functions
iex> Mahaul.Constants.error_tuple()
{:error, nil}
iex> Mahaul.Constants.mix_env()
:prod
iex> Mahaul.Constants.required_opts()
[:type]
iex> Mahaul.Constants.supported_types()
[:str, :enum, :num, :int, :bool, :port, :host, :uri]
Link to this section Types
@type config_type() :: keyword()
The configuration options type.
@type error_type() :: {:error, nil}
The common error type.
@type normalized_value_type() :: {atom(), error_type() | success_type()}
The type representing a normalized environment variable value.
@type normalized_values_type() :: [normalized_value_type()]
The type representing list of all normalized environment variable values.
@type success_type() :: {:ok, value_type()}
The common success type.
The supported environment variable value type.
@type var_type() :: :str | :num | :int | :bool | :port | :host | :uri
The supported environment variable type.
Link to this section Functions
iex> Mahaul.Constants.error_tuple()
{:error, nil}
iex> Mahaul.Constants.mix_env()
:prod
iex> Mahaul.Constants.required_opts()
[:type]
iex> Mahaul.Constants.supported_types()
[:str, :enum, :num, :int, :bool, :port, :host, :uri]