| Disk ARchive 2.6.11 Full featured and portable backup and archiving tool

Files | Classes | Macros | Functions | Variables
API5

APplication Interface backward compatibility for API version 5. More...

## Files
file | archive5.hpp
| API v5 backward compatible class archive.
file | archive_options5.hpp
| API v5 compatible archive_options_* classes.
file | database5.hpp
| this file holds the database class definition as defined in API version 5
file | libdar5.hpp
| backward compatibility to libdar API 5
file | user_interaction5.hpp
| API v5 backward compatible class user_interaction.
file | user_interaction_callback5.hpp
| API v5 backward compatible user_interaction_callback class.

## Classes
class | libdar5::archive
| the archive class realizes the most general operations on archives More...
class | libdar5::database
| the database class defines the dar_manager database More...
class | libdar5::user_interaction
| This is a pure virtual class that is used by libdar when interaction with the user is required. More...
class | libdar5::user_interaction_callback
| full implemented class for user_interaction based on callback functions. More...

## Macros
#define | LIBDAR_XXXXXXXX
| The following macro are used in the "exception" argument of the *_noexcept() functions.
#define | LIBDAR_NOEXCEPT 0
| normal return no exception has been thrown
#define | LIBDAR_EMEMORY 1
| memory has been exhausted
#define | LIBDAR_EBUG 2
| internal bug error.
#define | LIBDAR_EINFININT 3
| division by zero or other arithmetic error
#define | LIBDAR_ELIMITINT 4
| limitint overflow
#define | LIBDAR_ERANGE 5
| range error
#define | LIBDAR_EDECI 6
| decimal representation error
#define | LIBDAR_EFEATURE 7
| feature not (yet) implemented
#define | LIBDAR_EHARDWARE 8
| hardware failure
#define | LIBDAR_EUSER_ABORT 9
| user has aborted the operation
#define | LIBDAR_EDATA 10
| data inconsistency, error concerning the treated data
#define | LIBDAR_ESCRIPT 11
| inter slice script failure
#define | LIBDAR_ELIBCALL 12
| libdar invalid call (wrong argument given to call, etc.)
#define | LIBDAR_UNKNOWN 13
| unknown error
#define | LIBDAR_ECOMPILATION 14
| feature not activated at compilation time
#define | LIBDAR_THREAD_CANCEL 15
| thread cancellation has been requested

## Functions
compression | libdar5::char2compression (char a)
char | libdar5::compression2char (compression c)
std::string | libdar5::compression2string (compression c)
compression | libdar5::string2compression (const std::string &a)
fsa_scope | libdar5::all_fsa_families ()
mycurl_protocol | libdar5::string_to_mycurl_protocol (const std::string &arg)
void | libdar5::get_version (U_I &major, U_I &medium, U_I &minor, bool init_libgcrypt=true)
| return the libdar version, and make libdar initialization (may throw Exceptions) More...
void | libdar5::get_version_noexcept (U_I &major, U_I &medium, U_I &minor, U_16 &exception, std::string &except_msg, bool init_libgcrypt=true)
| return the libdar version, and make libdar initialization (does not throw exceptions) More...
void | libdar5::close_and_clean ()
archive * | libdar5::open_archive_noexcept (user_interaction &dialog, const path &chem, const std::string &basename, const std::string &extension, const archive_options_read &options, U_16 &exception, std::string &except_msg)
| this is a wrapper around the archive constructor known as the "read" constructor More...
archive * | libdar5::create_archive_noexcept (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, U_16 &exception, std::string &except_msg)
| this is a wrapper around the archive constructor known as the "create" constructor More...
archive * | libdar5::isolate_archive_noexcept (user_interaction &dialog, archive *ptr, const path &sauv_path, const std::string &filename, const std::string &extension, const archive_options_isolate &options, U_16 &exception, std::string &except_msg)
| this is a wrapper around the archive constructor known as the "isolate" constructor More...
archive * | libdar5::merge_archive_noexcept (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, U_16 &exception, std::string &except_msg)
| this is a wrapper around the archive constructor known as the "merging" constructor More...
void | libdar5::close_archive_noexcept (archive *ptr, U_16 &exception, std::string &except_msg)
| this is wrapper around the archive destructor More...
statistics | libdar5::op_extract_noexcept (user_interaction &dialog, archive *ptr, const path &fs_root, const archive_options_extract &options, statistics *progressive_report, U_16 &exception, std::string &except_msg)
| this is wrapper around the op_extract method More...
void | libdar5::op_listing_noexcept (user_interaction &dialog, archive *ptr, const archive_options_listing &options, U_16 &exception, std::string &except_msg)
| this is wrapper around the op_listing method More...
statistics | libdar5::op_diff_noexcept (user_interaction &dialog, archive *ptr, const path &fs_root, const archive_options_diff &options, statistics *progressive_report, U_16 &exception, std::string &except_msg)
| this is wrapper around the op_diff method More...
statistics | libdar5::op_test_noexcept (user_interaction &dialog, archive *ptr, const archive_options_test &options, statistics *progressive_report, U_16 &exception, std::string &except_msg)
| this is wrapper around the op_test method More...
bool | libdar5::get_children_of_noexcept (user_interaction &dialog, archive *ptr, const std::string &dir, U_16 &exception, std::string &except_msg)
| this is wrapper around the get_children_of method More...
char * | libdar5::libdar_str2charptr_noexcept (const std::string &x, U_16 &exception, std::string &except_msg)
| routine provided to convert std::string to char * More...
std::shared_ptr< user_interaction > | libdar5::user_interaction5_clone_to_shared_ptr (user_interaction &dialog)
| convert a user_interaction to a shared_pointer on a clone of that user_interaction

## Variables
constexpr compression | libdar5::none = compression::none
constexpr compression | libdar5::gzip = compression::gzip
constexpr compression | libdar5::bzip2 = compression::bzip2
constexpr compression | libdar5::lzo = compression::lzo
constexpr compression | libdar5::xz = compression::xz
constexpr compression | libdar5::lzo1x_1_15 = compression::lzo1x_1_15
constexpr compression | libdar5::lzo1x_1 = compression::lzo1x_1
constexpr crypto_algo | libdar5::crypto_none = crypto_algo::none
constexpr crypto_algo | libdar5::crypto_scrambling = crypto_algo::scrambling
constexpr crypto_algo | libdar5::crypto_blowfish = crypto_algo::blowfish
constexpr crypto_algo | libdar5::crypto_aes256 = crypto_algo::aes256
constexpr crypto_algo | libdar5::crypto_twofish256 = crypto_algo::twofish256
constexpr crypto_algo | libdar5::crypto_serpent256 = crypto_algo::serpent256
constexpr crypto_algo | libdar5::crypto_camellia256 = crypto_algo::camellia256
constexpr capa_status | libdar5::capa_set = libdar::capa_status::capa_set
constexpr capa_status | libdar5::capa_clear = libdar::capa_status::capa_clear
constexpr capa_status | libdar5::capa_unknown = libdar::capa_status::capa_unknown
constexpr over_action_data | libdar5::data_preserve = libdar::over_action_data::data_preserve
constexpr over_action_data | libdar5::data_overwrite = libdar::over_action_data::data_overwrite
constexpr over_action_data | libdar5::data_preserve_mark_already_saved = libdar::over_action_data::data_preserve_mark_already_saved
constexpr over_action_data | libdar5::data_overwrite_mark_already_saved = libdar::over_action_data::data_overwrite_mark_already_saved
constexpr over_action_data | libdar5::data_remove = libdar::over_action_data::data_remove
constexpr over_action_data | libdar5::data_undefined = libdar::over_action_data::data_undefined
constexpr over_action_data | libdar5::data_ask = libdar::over_action_data::data_ask
constexpr over_action_ea | libdar5::EA_preserve = libdar::over_action_ea::EA_preserve
constexpr over_action_ea | libdar5::EA_overwrite = libdar::over_action_ea::EA_overwrite
constexpr over_action_ea | libdar5::EA_clear = libdar::over_action_ea::EA_clear
constexpr over_action_ea | libdar5::EA_preserve_mark_already_saved = libdar::over_action_ea::EA_preserve_mark_already_saved
constexpr over_action_ea | libdar5::EA_overwrite_mark_already_saved = libdar::over_action_ea::EA_overwrite_mark_already_saved
constexpr over_action_ea | libdar5::EA_merge_preserve = libdar::over_action_ea::EA_merge_preserve
constexpr over_action_ea | libdar5::EA_merge_overwrite = libdar::over_action_ea::EA_merge_overwrite
constexpr over_action_ea | libdar5::EA_undefined = libdar::over_action_ea::EA_undefined
constexpr over_action_ea | libdar5::EA_ask = libdar::over_action_ea::EA_ask
constexpr hash_algo | libdar5::hash_none = hash_algo::none
constexpr hash_algo | libdar5::hash_md5 = hash_algo::md5
constexpr hash_algo | libdar5::hash_sha1 = hash_algo::sha1
constexpr hash_algo | libdar5::hash_sha512 = hash_algo::sha512
constexpr fsa_family | libdar5::fsaf_hfs_plus = fsa_family::fsaf_hfs_plus
constexpr fsa_family | libdar5::fsaf_linux_extX = fsa_family::fsaf_linux_extX
constexpr fsa_nature | libdar5::fsan_unset = fsa_nature::fsan_unset
constexpr fsa_nature | libdar5::fsan_creation_date = fsa_nature::fsan_creation_date
constexpr fsa_nature | libdar5::fsan_append_only = fsa_nature::fsan_append_only
constexpr fsa_nature | libdar5::fsan_compressed = fsa_nature::fsan_compressed
constexpr fsa_nature | libdar5::fsan_no_dump = fsa_nature::fsan_no_dump
constexpr fsa_nature | libdar5::fsan_immutable = fsa_nature::fsan_immutable
constexpr fsa_nature | libdar5::fsan_data_journaling = fsa_nature::fsan_data_journaling
constexpr fsa_nature | libdar5::fsan_secure_deletion = fsa_nature::fsan_secure_deletion
constexpr fsa_nature | libdar5::fsan_no_tail_merging = fsa_nature::fsan_no_tail_merging
constexpr fsa_nature | libdar5::fsan_undeletable = fsa_nature::fsan_undeletable
constexpr fsa_nature | libdar5::fsan_noatime_update = fsa_nature::fsan_noatime_update
constexpr fsa_nature | libdar5::fsan_synchronous_directory = fsa_nature::fsan_synchronous_directory
constexpr fsa_nature | libdar5::fsan_synchronous_udpdate = fsa_nature::fsan_synchronous_update
constexpr fsa_nature | libdar5::fsan_top_of_dir_hierarchy = fsa_nature::fsan_top_of_dir_hierarchy
constexpr gf_mode | libdar5::gf_read_only = gf_mode::gf_read_only
constexpr gf_mode | libdar5::gf_write_only = gf_mode::gf_write_only
constexpr gf_mode | libdar5::gf_read_write = gf_mode::gf_read_write
constexpr mycurl_protocol | libdar5::proto_ftp = mycurl_protocol::proto_ftp
constexpr mycurl_protocol | libdar5::proto_sftp = mycurl_protocol::proto_sftp
constexpr comparison_fields | libdar5::cf_all = comparison_fields::all
constexpr comparison_fields | libdar5::cf_ignore_owner = comparison_fields::ignore_owner
constexpr comparison_fields | libdar5::cf_mtime = comparison_fields::mtime
constexpr comparison_fields | libdar5::cf_inode_type = comparison_fields::inode_type
const U_I | libdar5::LIBDAR_COMPILE_TIME_MAJOR = 5
| libdar Major version defined at compilation time
const U_I | libdar5::LIBDAR_COMPILE_TIME_MEDIUM = 100
| libdar Medium version defined at compilation time
const U_I | libdar5::LIBDAR_COMPILE_TIME_MINOR = 11
| libdar Minor version defined at compilation time

## Detailed Description

APplication Interface backward compatibility for API version 5.

backward compatible namespace with dar/libdar releases 2.5.x and 2.4.x

## Function Documentation

## ◆ close_archive_noexcept()

void libdar5::close_archive_noexcept | ( | archive * | ptr,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the archive destructor

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ create_archive_noexcept()

archive* libdar5::create_archive_noexcept | ( | 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,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is a wrapper around the archive constructor known as the "create" constructor

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ get_children_of_noexcept()

bool libdar5::get_children_of_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const std::string & | dir,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the get_children_of method

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ get_version()

void libdar5::get_version | ( | U_I & | major,
|  | U_I & | medium,
|  | U_I & | minor,
|  | bool | init_libgcrypt = `true`
| ) |  |

return the libdar version, and make libdar initialization (may throw Exceptions)

It is mandatory to call this function (or another one of the get_version* family)

Parameters

  [out] | major | the major number of the version
  [out] | medium | the medium number of the version
  [out] | minor | the minor number of the version
  [in] | init_libgcrypt | whether to initialize libgcrypt if not already done (not used if libcrypt is not linked with libdar)

Note
  the calling application must match that the major function is the same as the libdar used at compilation time. See API tutorial for a sample code.

## ◆ get_version_noexcept()

void libdar5::get_version_noexcept | ( | U_I & | major,
|  | U_I & | medium,
|  | U_I & | minor,
|  | U_16 & | exception,
|  | std::string & | except_msg,
|  | bool | init_libgcrypt = `true`
| ) |  |

return the libdar version, and make libdar initialization (does not throw exceptions)

It is mandatory to call this function (or another one of the get_version* family)

Parameters

  [out] | major | the major number of the version
  [out] | medium | the medium number of the version
  [out] | minor | the minor number of the version
  [out] | exception | is to be compared with the LIBDAR_* macro to know whether the call succeeded
  [out] | except_msg | in case exception is not equal to LIBDAR_NOEXCEPT this argument contains
  [in] | init_libgcrypt | whether to initialize libgcrypt if not already done (not used if libcrypt is not linked with libdar) a human readable explaination of the error met.

Note
  the calling application must match that the major function is the same as the libdar used at compilation time. See API tutorial for a sample code.

## ◆ isolate_archive_noexcept()

archive* libdar5::isolate_archive_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const path & | sauv_path,
|  | const std::string & | filename,
|  | const std::string & | extension,
|  | const archive_options_isolate & | options,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is a wrapper around the archive constructor known as the "isolate" constructor

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ libdar_str2charptr_noexcept()

char* libdar5::libdar_str2charptr_noexcept | ( | const std::string & | x,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

routine provided to convert std::string to char *

Parameters

  [in] | x | the string to convert
  [out] | exception | the return status of the call
  [out] | except_msg | the message taken from the caught exception in case of error for an explaination of the two last arguments exception and except_msg check the get_version_noexcept function

Returns
  the address of a newly allocated memory which must be released calling the "delete []" operator when no more needed.
  nullptr in case of error

## ◆ merge_archive_noexcept()

archive* libdar5::merge_archive_noexcept | ( | 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,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is a wrapper around the archive constructor known as the "merging" constructor

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ op_diff_noexcept()

statistics libdar5::op_diff_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const path & | fs_root,
|  | const archive_options_diff & | options,
|  | statistics * | progressive_report,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the op_diff method

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ op_extract_noexcept()

statistics libdar5::op_extract_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const path & | fs_root,
|  | const archive_options_extract & | options,
|  | statistics * | progressive_report,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the op_extract method

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ op_listing_noexcept()

void libdar5::op_listing_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const archive_options_listing & | options,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the op_listing method

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ op_test_noexcept()

statistics libdar5::op_test_noexcept | ( | user_interaction & | dialog,
|  | archive * | ptr,
|  | const archive_options_test & | options,
|  | statistics * | progressive_report,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is wrapper around the op_test method

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function

## ◆ open_archive_noexcept()

archive* libdar5::open_archive_noexcept | ( | user_interaction & | dialog,
|  | const path & | chem,
|  | const std::string & | basename,
|  | const std::string & | extension,
|  | const archive_options_read & | options,
|  | U_16 & | exception,
|  | std::string & | except_msg
| ) |  |

this is a wrapper around the archive constructor known as the "read" constructor

check the archive class for details for an explaination of the two extra arguments exception and except_msg check the get_version_noexcept function