Config::Wrest

Read and write Configuration data With References, Environment variables, Sections, and Templating
Download

Config::Wrest Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • BBC
  • Publisher web site:
  • http://www.bbc.co.uk

Config::Wrest Tags


Config::Wrest Description

Read and write Configuration data With References, Environment variables, Sections, and Templating Config::Wrest is a Perl module that allows you to read configuration data written in a human-readable and easily-editable text format and access it as a perl data structure. It also allows you to write configuration data from perl back to this format.The data format allows key/value pairs, comments, escaping of unprintable or problematic characters, sensible whitespace handling, support for Unicode data, nested sections, or blocks, of configuration data (analogous to hash- and array-references), and the optional preprocessing of each line through a templating engine. If you choose to use a templating engine then, depending on the engine you're using, you can interpolate other values into the data, interpolate environment variables, and perform other logic or transformations. The data format also allows you to use directives to alter the behaviour of the parser from inside the configuration file, to set variables, to include other files, and for other actions.SYNOPSIS use Config::Wrest; my $c = new Config::Wrest(); # Read configuration data from a string, or from a reference to a string my $vars; $vars = $c->deserialize($string); $vars = $c->deserialize($string); # Write configuration data as a string my $string = $c->serialize(\%vars); # ...write the data into a specific scalar $c->serialize(\%vars, $string); # Convenience methods to interface with files $vars = $c->parse_file($filename); $c->write_file($filename, \%vars); Requirements: · Perl


Config::Wrest Related Software