NAME

Games::Risk::Config - prisk configuration

VERSION

version 4.000

SYNOPSIS

use Games::Risk::Config;
my $config = Games::Risk::Config->instance;
my $val = $config->get( "foo.bar.baz" );
$config->set( "foo.bar.baz", 42 );
$config->save;

DESCRIPTION

This module implements a basic persistant configuration. The configuration is storead as YAML, yet keys are flattened using dots - eg, a foo.bar.baz key will fetch at depth 3.

METHODS

save

$config->save;

Save $config to its on-disk file.

get

my $value = $config->get( $key );

Return the $value associated to $key in $config.

set

$config->set( $key, $value );

Associate a given $value to a $key in $config.

AUTHOR

Jerome Quelin

COPYRIGHT AND LICENSE

This software is Copyright (c) 2008 by Jerome Quelin.

This is free software, licensed under:

The GNU General Public License, Version 3, June 2007