Vapor v0.3.0 Vapor behaviour View Source
Vapor provides mechanisms for handling runtime configuration in your system.
Link to this section Summary
Functions
Starts a configuration store and any watches
Stops the configuration store and any watches
Callbacks
Fetches a value from the config under the key provided
Optional callback. Called when the configuration server starts. Passes the map of the reified values
Set the value under the key in the store
Link to this section Types
Link to this type
key() View Source
Link to this type
type()
View Source
type()
View Source
type() :: :string | :int | :float | :bool
type() :: :string | :int | :float | :bool
Link to this type
value() View Source
Link to this section Functions
Link to this function
start_link(module, config, opts) View Source
Starts a configuration store and any watches.
Link to this function
stop(name) View Source
Stops the configuration store and any watches.
Link to this section Callbacks
Link to this callback
get(key) View Source
Fetches a value from the config under the key provided.
Example
VaporExample.Config.get(:key)
Link to this callback
init(list) View Source
Optional callback. Called when the configuration server starts. Passes the map of the reified values.
Link to this callback
set(key, value) View Source
Set the value under the key in the store.
Example
VaporExample.Config.set(:key, "value")