Util::Properties - Java.util.properties like class
rimplement something like ava.util.Properties API.
The main differences with CPAN existant Config::Properties and Data::Properties is file locking & autoload/autosave features
Create a new prop system from either:
Get/set a name for the set of prperty (mainly used for debugging or code clarity purpose
Get/set (set if an argument is passed) a boolean value to determine if the file is to be file with property (if any is defined) is to be kept coherent with the data. This mean that any set of property will be mirrored on the file, and before any get, the file time stamp will be check to see if the data has changed into the file.
Get/set the filename
Get/set the md5 of the file
Set if a file locker is to be used (or a file locker is you do not wish to use the default). A die will be thrown if locking fails
Get the file locker (or undef).
get/set is it is possible for the file not to exist (in this case, no problem not to save...)
get property defined by key;
Set a property
return a hash with all the properties
Clean the properties list;
return true if the properties does not contain any fields
load properties from $prop->file_name
Save properties from $prop->file_name (comment have been forgotten)
If a file_locker is to be defined by default creator [default is 1]
If data in memory must be consistent with file (based on file maodification time) [default is 1]
verbose level;
Alexandre Masselot, <alexandre.masselot@genebio.com>
<alexandre.masselot@genebio.com>
Please report any bugs or feature requests to bug-util-properties@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Util-Properties. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-util-properties@rt.cpan.org
Copyright 2006 Alexandre Masselot, all rights reserved.
This program is released under the following license: gpl
To install Util::Properties, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Util::Properties
CPAN shell
perl -MCPAN -e shell install Util::Properties
For more information on module installation, please visit the detailed CPAN module installation guide.