Data::Hive::Store - a backend storage driver for Data::Hive
version 1.015
Data::Hive::Store is a generic interface to a backend store for Data::Hive.
This library should run on perls released even a long time ago. It should work on any version of perl released in the last five years.
Although it may work on older versions of perl, no guarantee is made that the minimum required version will not be increased. The version may be increased for any reason, and there is no promise that patches will be accepted to lower the minimum required perl.
All methods are passed at least a 'path' (arrayref of namespace pieces). Store classes exist to operate on the entities found at named paths.
print $store->get(\@path, \%opt);
Return the resource represented by the given path.
$store->set(\@path, $value, \%opt);
Analogous to get.
get
print $store->name(\@path, \%opt);
Return a store-specific name for the given path. This is primarily useful for stores that may be accessed independently of the hive.
if ($store->exists(\@path, \%opt)) { ... }
Returns true if the given path exists in the store.
$store->delete(\@path, \%opt);
Delete the given path from the store. Return the previous value, if any.
Stores can also implement delete_all to delete this path and all paths below it. If delete_all is not provided, the generic one-by-one delete in this class will be used.
delete_all
my @keys = $store->keys(\@path, \%opt);
This returns a list of next-level path elements that lead toward existing values. For more information on the expected behavior, see the KEYS method in Data::Hive.
Hans Dieter Pearcey <hdp@cpan.org>
Ricardo Signes <cpan@semiotic.systems>
This software is copyright (c) 2006 by Hans Dieter Pearcey.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Data::Hive, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Data::Hive
CPAN shell
perl -MCPAN -e shell install Data::Hive
For more information on module installation, please visit the detailed CPAN module installation guide.