FusionInventory::Agent::Storage - the light data storage API. Data will be stored in a subdirectory in the 'vardir' directory. This subdirectory depends on the caller module name.
my $storage = FusionInventory::Agent::Storage->new({ target => { vardir => $ARGV[0], } }); my $data = $storage->restore({ module => "FusionInventory::Agent" }); $data->{foo} = 'bar'; $storage->save({ data => $data });
This module is a wrapper for restore and save. it called $inventory in general.
Create the object
Save the reference. $idx is an integer. You can use it if you want to save more than one file for the module. This number will be added at the of the file.
Returns a reference to the stored data. If $idx is defined, it will open this substorage.
Returns the files stored on the filesystem for the module $module or for the caller module. If $idx is defined, only the submodule $idx will be removed.
Deletes the files stored on the filesystem for the module $module or for the caller module.
Deletes the sub files stored on the filesystem for the module $module or for the caller module.
1 POD Error
The following errors were encountered while parsing the POD:
=over without closing =back
To install FusionInventory::Agent, copy and paste the appropriate command in to your terminal.
cpanm
cpanm FusionInventory::Agent
CPAN shell
perl -MCPAN -e shell install FusionInventory::Agent
For more information on module installation, please visit the detailed CPAN module installation guide.