ZMSettings
public class ZMSettings
| Method Summary | |
|---|---|
| static void | addAll(array settings, boolean replace) Add a map of settings. |
| static mixed | append(string name, mixed value, string delim) Append configuration value. |
| static boolean | exists(string name) Check if a given setting exists. |
| static mixed | get(string name, mixed default) Get the value for the given setting name. |
| static array | getAll() Get a map of all settings. |
| void | load(string yaml, boolean override) Load mappings from a YAML style string. |
| static mixed | set(string name, mixed value) Set configuration value. |
| static void | setAll(array settings) Set a map of all settings. |
public static void addAll(array settings, boolean replace)
Add a map of settings.
true existing settings will be replaced; default is true.public static mixed append(string name, mixed value, string delim)
Append configuration value.
null.public static boolean exists(string name)
Check if a given setting exists.
This is useful in cases where null is a valid setting value. In that
case, the get method will be ambiguous and exists should
be used.
true if a setting with the given name exists.public static mixed get(string name, mixed default)
Get the value for the given setting name.
null.null.public static array getAll()
Get a map of all settings.
public void load(string yaml, boolean override)
Load mappings from a YAML style string.
true to override.public static mixed set(string name, mixed value)
Set configuration value.
null.public static void setAll(array settings)
Set a map of all settings.
Settings (ZenMagick's configuration).