Disk ARchive
2.4.5
|
the archive class realizes the most general operations on archives More...
#include <archive.hpp>
Inherited by libdar_4_4::archive.
Public Member Functions | |
archive (user_interaction &dialog, const path &chem, const std::string &basename, const std::string &extension, const archive_options_read &options) | |
this constructor opens an already existing archive (for reading) [this is the "read" constructor] | |
archive (user_interaction &dialog, const path &fs_root, const path &sauv_path, const std::string &filename, const std::string &extension, const archive_options_create &options, statistics *progressive_report) | |
this constuctor create an archive (full or differential) [this is the "create" constructor] | |
archive (user_interaction &dialog, const path &sauv_path, archive *ref_arch, const std::string &filename, const std::string &extension, const archive_options_isolate &options) | |
this constructor isolates a catalogue of a given archive [this is the "isolate" constructor] | |
archive (user_interaction &dialog, const path &sauv_path, archive *ref_arch1, const std::string &filename, const std::string &extension, const archive_options_merge &options, statistics *progressive_report) | |
this constructor builds an archive from two given archive [this is the "merge" constructor] | |
archive (const archive &ref) | |
copy constructor (not implemented, throw an exception if called explicitely or implicitely) | |
archive & | operator= (const archive &ref) |
~archive () | |
the destructor | |
statistics | op_extract (user_interaction &dialog, const path &fs_root, const archive_options_extract &options, statistics *progressive_report) |
extraction of data from an archive | |
void | summary (user_interaction &dialog) |
display a summary of the archive | |
void | op_listing (user_interaction &dialog, const archive_options_listing &options) |
listing of the archive contents | |
statistics | op_diff (user_interaction &dialog, const path &fs_root, const archive_options_diff &options, statistics *progressive_report) |
archive comparison with filesystem | |
statistics | op_test (user_interaction &dialog, const archive_options_test &options, statistics *progressive_report) |
test the archive integrity | |
bool | get_children_of (user_interaction &dialog, const std::string &dir) |
getting information about a given directory | |
const entree_stats | get_stats () const |
retrieving statistics about archive contents | |
const catalogue & | get_catalogue () const |
gives access to internal catalogue (not to be used from the API) | |
const catalogue & | get_catalogue (user_interaction &dialog) const |
gives access to internal catalogue (not to be used from the API) even in sequential read mode | |
void | drop_all_filedescriptors () |
closes all filedescriptors and associated data, just keep the catalogue | |
void | drop_all_filedescriptors (user_interaction &dialog) |
closes all filedescriptors and associated even when in sequential read mode |
the archive class realizes the most general operations on archives
the operations corresponds to the one the final user expects, these are the same abstraction level as the operation realized by the DAR command line tool.
Definition at line 53 of file archive.hpp.
libdar::archive::archive | ( | user_interaction & | dialog, |
const path & | chem, | ||
const std::string & | basename, | ||
const std::string & | extension, | ||
const archive_options_read & | options | ||
) |
this constructor opens an already existing archive (for reading) [this is the "read" constructor]
[in,out] | dialog | for user interaction |
[in] | chem | the path where to look for slices |
[in] | basename | the slices basename of the archive to read ("-" means standard input, and activates the output_pipe and input_pipe arguments) |
[in] | extension | the slice extension (should always be "dar") |
[in] | options | A set of option to use to read the archive |
libdar::archive::archive | ( | user_interaction & | dialog, |
const path & | fs_root, | ||
const path & | sauv_path, | ||
const std::string & | filename, | ||
const std::string & | extension, | ||
const archive_options_create & | options, | ||
statistics * | progressive_report | ||
) |
this constuctor create an archive (full or differential) [this is the "create" constructor]
[in,out] | dialog | for user interaction |
[in] | fs_root | the filesystem to take as root for the backup |
[in] | sauv_path | the path where to create slices |
[in] | filename | base name of the slices. If "-" is given the archive will be produced in standard output |
[in] | extension | slices extension ("dar") |
[in] | options | optional parameters to use for the operation |
[out] | progressive_report | statistics about the operation, considering the treated files (NULL can be given if you don't want to use this feature) |
libdar::archive::archive | ( | user_interaction & | dialog, |
const path & | sauv_path, | ||
archive * | ref_arch, | ||
const std::string & | filename, | ||
const std::string & | extension, | ||
const archive_options_isolate & | options | ||
) |
this constructor isolates a catalogue of a given archive [this is the "isolate" constructor]
[in,out] | dialog | for user interaction |
[in] | sauv_path | the path where to create slices |
[in] | ref_arch | the archive to take as reference (NULL for a full backup) |
[in] | filename | base name of the slices ("-" for standard output) |
[in] | extension | slices extension ("dar") |
[in] | options | optional parameters to use for the operation |
libdar::archive::archive | ( | user_interaction & | dialog, |
const path & | sauv_path, | ||
archive * | ref_arch1, | ||
const std::string & | filename, | ||
const std::string & | extension, | ||
const archive_options_merge & | options, | ||
statistics * | progressive_report | ||
) |
this constructor builds an archive from two given archive [this is the "merge" constructor]
[in,out] | dialog | for user interaction |
[in] | sauv_path | the path where to create slices |
[in] | ref_arch1 | the first mandatory input archive (the second is optional and provided within the 'option' argument |
[in] | filename | base name of the slices. If "-" is given the archive will be produced in standard output |
[in] | extension | slices extension ("dar") |
[in] | options | optional parameters to be used for the operation |
[out] | progressive_report | statistics about the operation, considering the treated files (NULL can be given if you don't want to use this feature) |
libdar::archive::archive | ( | const archive & | ref | ) | [inline] |
copy constructor (not implemented, throw an exception if called explicitely or implicitely)
Definition at line 149 of file archive.hpp.
closes all filedescriptors and associated data, just keep the catalogue
const catalogue& libdar::archive::get_catalogue | ( | ) | const |
gives access to internal catalogue (not to be used from the API)
bool libdar::archive::get_children_of | ( | user_interaction & | dialog, |
const std::string & | dir | ||
) |
getting information about a given directory
[in,out] | dialog | for user interaction |
[in] | dir | relative path the directory to get information about |
statistics libdar::archive::op_diff | ( | user_interaction & | dialog, |
const path & | fs_root, | ||
const archive_options_diff & | options, | ||
statistics * | progressive_report | ||
) |
archive comparison with filesystem
[in,out] | dialog | for user interaction |
[in] | fs_root | the filesystem to take as root for the comparison |
[in] | options | optional parameters to be used with the operation |
[in,out] | progressive_report | points to an already existing statistics object that can be consulted at any time during the call (see the returned value to know the useful fields and their meining), NULL can be given in argument if you only need the result at the end of the operation through the returned value of this call this should speed up the operation by a little amount. |
statistics libdar::archive::op_extract | ( | user_interaction & | dialog, |
const path & | fs_root, | ||
const archive_options_extract & | options, | ||
statistics * | progressive_report | ||
) |
extraction of data from an archive
[in,out] | dialog | for user interaction |
[in] | fs_root | the filesystem to take as root for the restoration |
[in] | options | optional parameter to be used for the operation |
[in,out] | progressive_report | points to an already existing statistics object that can be consulted at any time during the call (see the returned value to know the useful fields and their meining), NULL can be given in argument if you only need the result at the end of the operation through the returned value of this call this should speed up the operation by a little amount. |
void libdar::archive::op_listing | ( | user_interaction & | dialog, |
const archive_options_listing & | options | ||
) |
listing of the archive contents
[in,out] | dialog | for user interaction |
[in] | options | list of optional parameters to use for the operation |
statistics libdar::archive::op_test | ( | user_interaction & | dialog, |
const archive_options_test & | options, | ||
statistics * | progressive_report | ||
) |
test the archive integrity
[in,out] | dialog | for user interaction |
[in] | options | optional parameter to use for the operation |
[in,out] | progressive_report | points to an already existing statistics object that can be consulted at any time during the call (see the returned value to know the useful fields and their meining), NULL can be given in argument if you only need the result at the end of the operation through the returned value of this call this should speed up the operation by a little amount. |