WE::Export - export a WE::DB database
use WE::Export; my $r = new WE::DB ...; my $ex = new WE::Export $r; $ex->export_all;
This module provides export and import methods for the WE::DB database.
Called as new WE::Export $rootdb. Create a new WE::Export object for the given database $rootdb. Additional arguments (as dashed key-value pairs) will be passed to the object.
new WE::Export $rootdb
$rootdb
Create data dumper files of the metadata databases and store them into the directory specified by the Tmpdir member. Data::Dumper files are created because most DBM file formats are incompatible between various systems.
Tmpdir
Copy the content files to the content subdirectory of the directory specified by the Tmpdir member.
content
Create an archive file (.tar.gz format) of both database and content. Two member variables control paths for the export: Tmpdir specifies the temporary directory, where database and content files will be stored, and Archive specifies the path for the generated archive file. If not specified, then reasonable defaults are chosen (using the systems default temp directory). After the creation of the archive file, the temporary directory will be deleted completely.
Archive
For the specified tar archive $tarfile (previously created by export_all), the content will be extracted to the directory $destdir. The destination directory must not exist and will be created by the method.
$tarfile
export_all
$destdir
Further arguments %args:
Be verbose.
Extract even if destination directory exists.
Extract only specified databases. Note that content is always extracted.
Make chmod manipulations (set everything to 0777 resp. 0666) if set to true.
This module will only work on Windows with installed Archive::Tar and Compress::Zlib (this is usually true with ActivePerl). On Unix, you need the programs tar and gzip.
tar
gzip
Slaven Rezic - slaven@rezic.de
To install WE::DB, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WE::DB
CPAN shell
perl -MCPAN -e shell install WE::DB
For more information on module installation, please visit the detailed CPAN module installation guide.