NAME
Xango::Config - Global Xango Config
SYNOPSIS
use Xango::Config;
Xango::Config->init($filename);
# or
use Xango::Config ($filename);
# elsewhere in the code...
my $config = Xango::Config->instance();
DESCRIPTION
Xango::Config is a singleton object that contains all configuration variables for Xango system. It's a singleton that reads input files from a YAML file.
All the variables specified in the file is available from the param() method as Perl data structures.
METHODS
init($filename[, \%opts])
Class method that initializes the config with the contents in the YAML file. Once initialized, subsequent calls to init() has no effect unless force_reload is specified in the options hash:
Xango::Config->init($file, { force_reload => 1 });
instance()
Returns the current instance of Xango::Config. will return undef unless you have initialized the instance by calling init().
param($name[, $value])
Get/Set the value of a config variable. Returns whatever Perl structure that you have specified in the config file.
Since Xango::Config is an You may use param() as both a class method or an instance method
AUTHOR
Daisuke Maki <dmaki@cpan.org> Development funded by Brazil, Ltd. <http://b.razil.jp>