NAME

AI::Evolve::Befunge::Util::Config - config database object

SYNOPSIS

use AI::Evolve::Befunge::Util;
my $config = custom_config(host => 'test', physics => 'ttt', gen => 1024);
my $value = $config->config('value', 'default');

DESCRIPTION

This is a config object. The config file allows overrides based on hostname, physics engine in use, and AI generation. Thus, the config file data needs to be re-assessed every time one of these (usually just the generation) is changed. The result of this is a Config object, which is what this module implements.

CONSTRUCTOR

custom_config

This module does not actually implement the constructor - please see custom_config() in AI::Evolve::Befunge::Util for the details.

METHODS

config

my $value = global_config('name');
my $value = global_config('name', 'default');
my @list  = global_config('name', 'default');
my @list  = global_config('name', ['default1', 'default2']);

Fetch some data from the config object.