Disk ARchive 2.7.16
Full featured and portable backup and archiving tool
libdar5.hpp
Go to the documentation of this file.
1/*********************************************************************/
2// dar - disk archive - a backup/restoration program
3// Copyright (C) 2002-2024 Denis Corbin
4//
5// This program is free software; you can redistribute it and/or
6// modify it under the terms of the GNU General Public License
7// as published by the Free Software Foundation; either version 2
8// of the License, or (at your option) any later version.
9//
10// This program is distributed in the hope that it will be useful,
11// but WITHOUT ANY WARRANTY; without even the implied warranty of
12// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13// GNU General Public License for more details.
14//
15// You should have received a copy of the GNU General Public License
16// along with this program; if not, write to the Free Software
17// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18//
19// to contact the author, see the AUTHOR file
20/*********************************************************************/
21
25
26
27#ifndef LIBDAR5_HPP
28#define LIBDAR5_HPP
29
30#include "../my_config.h"
31
32extern "C"
33{
34#if MUTEX_WORKS
35#if HAVE_PTHREAD_H
36#include <pthread.h>
37#endif
38#endif
39}
40
41#include <string>
42#include "compressor.hpp"
43#include "path.hpp"
44#include "mask.hpp"
45#include "mask_list.hpp"
46#include "integers.hpp"
47#include "infinint.hpp"
48#include "statistics.hpp"
49#include "user_interaction.hpp"
51#include "deci.hpp"
52#include "archive5.hpp"
53#include "crypto.hpp"
56#include "capabilities.hpp"
57#include "entrepot_libcurl5.hpp"
58#include "fichier_local.hpp"
59#include "entrepot_local.hpp"
60#include "data_tree.hpp"
61#include "database5.hpp"
62#include "tuyau.hpp"
63#include "archive_aux.hpp"
64#include "tools.hpp"
65
68
70#define LIBDAR_XXXXXXXX
71
73#define LIBDAR_NOEXCEPT 0
75#define LIBDAR_EMEMORY 1
77#define LIBDAR_EBUG 2
79#define LIBDAR_EINFININT 3
81#define LIBDAR_ELIMITINT 4
83#define LIBDAR_ERANGE 5
85#define LIBDAR_EDECI 6
87#define LIBDAR_EFEATURE 7
89#define LIBDAR_EHARDWARE 8
91#define LIBDAR_EUSER_ABORT 9
93#define LIBDAR_EDATA 10
95#define LIBDAR_ESCRIPT 11
97#define LIBDAR_ELIBCALL 12
99#define LIBDAR_UNKNOWN 13
101#define LIBDAR_ECOMPILATION 14
103#define LIBDAR_THREAD_CANCEL 15
105
107namespace libdar5
108{
111
112 // from integers.hpp
113 using libdar::U_8;
114 using libdar::U_16;
115 using libdar::U_32;
116 using libdar::U_64;
117 using libdar::U_I;
118 using libdar::S_8;
119 using libdar::S_16;
120 using libdar::S_32;
121 using libdar::S_64;
122 using libdar::S_I;
123
124 // from infinint.hpp
125 using libdar::infinint;
126
127 // from erreurs.hpp
128 using libdar::Egeneric;
129 using libdar::Ememory;
131 using libdar::Ebug;
132 using libdar::Einfinint;
133 using libdar::Elimitint;
134 using libdar::Edeci;
135 using libdar::Erange;
136 using libdar::Efeature;
137 using libdar::Ehardware;
138 using libdar::Edata;
140 using libdar::Escript;
141 using libdar::Elibcall;
144 using libdar::Esystem;
145
146 // from secu_string.hpp
148
149 // from path.hpp
150 using libdar::path;
151
152 // from compressor.hpp
154 constexpr compression none = compression::none;
155 constexpr compression gzip = compression::gzip;
156 constexpr compression bzip2 = compression::bzip2;
157 constexpr compression lzo = compression::lzo;
158 constexpr compression xz = compression::xz;
159 constexpr compression lzo1x_1_15 = compression::lzo1x_1_15;
160 constexpr compression lzo1x_1 = compression::lzo1x_1;
161
162 inline compression char2compression(char a) { return libdar::char2compression(a); }
163 inline char compression2char(compression c) { return libdar::compression2char(c); }
164 inline std::string compression2string(compression c) { return libdar::compression2string(c); }
165 inline compression string2compression(const std::string & a) { return libdar::string2compression(a); }
166
167 // from crypto.hpp
169 constexpr crypto_algo crypto_none = crypto_algo::none;
170 constexpr crypto_algo crypto_scrambling = crypto_algo::scrambling;
171 constexpr crypto_algo crypto_blowfish = crypto_algo::blowfish;
172 constexpr crypto_algo crypto_aes256 = crypto_algo::aes256;
173 constexpr crypto_algo crypto_twofish256 = crypto_algo::twofish256;
174 constexpr crypto_algo crypto_serpent256 = crypto_algo::serpent256;
175 constexpr crypto_algo crypto_camellia256 = crypto_algo::camellia256;
176
177 using libdar::signator;
178
179 // from statistics.hpp
180 using libdar::statistics;
181
182 // from list_entry.hpp
183 using libdar::list_entry;
184
185 // from entree_stats.hpp
187
188 // from archive.hpp
189 // using libdar::archive;
190
191 // from capabilities.hpp
193 constexpr capa_status capa_set = libdar::capa_status::capa_set;
194 constexpr capa_status capa_clear = libdar::capa_status::capa_clear;
195 constexpr capa_status capa_unknown = libdar::capa_status::capa_unknown;
196
197 // from mask.hpp
198 using libdar::mask;
199 using libdar::bool_mask;
202 using libdar::not_mask;
203 using libdar::et_mask;
204 using libdar::ou_mask;
208
209 // from deci.hpp
210 using libdar::deci;
211
212 // from thread_cancellation
214
215 // from data_tree.hpp
217
218 // from criterium.hpp
219 using libdar::criterium;
239 using libdar::crit_not;
240 using libdar::crit_and;
241 using libdar::crit_or;
242 using libdar::crit_invert;
243
244 // from crit_action.hpp
246 constexpr over_action_data data_preserve = libdar::over_action_data::data_preserve;
247 constexpr over_action_data data_overwrite = libdar::over_action_data::data_overwrite;
248 constexpr over_action_data data_preserve_mark_already_saved = libdar::over_action_data::data_preserve_mark_already_saved;
249 constexpr over_action_data data_overwrite_mark_already_saved = libdar::over_action_data::data_overwrite_mark_already_saved;
250 constexpr over_action_data data_remove = libdar::over_action_data::data_remove;
251 constexpr over_action_data data_undefined = libdar::over_action_data::data_undefined;
252 constexpr over_action_data data_ask = libdar::over_action_data::data_ask;
253
255 constexpr over_action_ea EA_preserve = libdar::over_action_ea::EA_preserve;
256 constexpr over_action_ea EA_overwrite = libdar::over_action_ea::EA_overwrite;
257 constexpr over_action_ea EA_clear = libdar::over_action_ea::EA_clear;
258 constexpr over_action_ea EA_preserve_mark_already_saved = libdar::over_action_ea::EA_preserve_mark_already_saved;
259 constexpr over_action_ea EA_overwrite_mark_already_saved = libdar::over_action_ea::EA_overwrite_mark_already_saved;
260 constexpr over_action_ea EA_merge_preserve = libdar::over_action_ea::EA_merge_preserve;
261 constexpr over_action_ea EA_merge_overwrite = libdar::over_action_ea::EA_merge_overwrite;
262 constexpr over_action_ea EA_undefined = libdar::over_action_ea::EA_undefined;
263 constexpr over_action_ea EA_ask = libdar::over_action_ea::EA_ask;
264
267 using libdar::testing;
268 using libdar::crit_chain;
269
270 // from mask_list.hpp
271 using libdar::mask_list;
272
273 // from hash_fichier.hpp
274 using libdar::hash_algo;
275 constexpr hash_algo hash_none = hash_algo::none;
276 constexpr hash_algo hash_md5 = hash_algo::md5;
277 constexpr hash_algo hash_sha1 = hash_algo::sha1;
278 constexpr hash_algo hash_sha512= hash_algo::sha512;
279
280 // from fsa_family.hpp
281 using libdar::fsa_family;
282 constexpr fsa_family fsaf_hfs_plus = fsa_family::fsaf_hfs_plus;
283 constexpr fsa_family fsaf_linux_extX = fsa_family::fsaf_linux_extX;
284
285 using libdar::fsa_nature;
286 constexpr fsa_nature fsan_unset = fsa_nature::fsan_unset;
287 constexpr fsa_nature fsan_creation_date = fsa_nature::fsan_creation_date;
288 constexpr fsa_nature fsan_append_only = fsa_nature::fsan_append_only;
289 constexpr fsa_nature fsan_compressed = fsa_nature::fsan_compressed;
290 constexpr fsa_nature fsan_no_dump = fsa_nature::fsan_no_dump;
291 constexpr fsa_nature fsan_immutable = fsa_nature::fsan_immutable;
292 constexpr fsa_nature fsan_data_journaling = fsa_nature::fsan_data_journaling;
293 constexpr fsa_nature fsan_secure_deletion = fsa_nature::fsan_secure_deletion;
294 constexpr fsa_nature fsan_no_tail_merging = fsa_nature::fsan_no_tail_merging;
295 constexpr fsa_nature fsan_undeletable = fsa_nature::fsan_undeletable;
296 constexpr fsa_nature fsan_noatime_update = fsa_nature::fsan_noatime_update;
297 constexpr fsa_nature fsan_synchronous_directory = fsa_nature::fsan_synchronous_directory;
298 constexpr fsa_nature fsan_synchronous_udpdate = fsa_nature::fsan_synchronous_update;
299 constexpr fsa_nature fsan_top_of_dir_hierarchy = fsa_nature::fsan_top_of_dir_hierarchy;
300
301 using libdar::fsa_scope;
302 inline fsa_scope all_fsa_families() { return libdar::all_fsa_families(); }
303
304 // from generic_file.hpp
306 using libdar::gf_mode;
307 constexpr gf_mode gf_read_only = gf_mode::gf_read_only;
308 constexpr gf_mode gf_write_only = gf_mode::gf_write_only;
309 constexpr gf_mode gf_read_write = gf_mode::gf_read_write;
310
311 // from tools.hpp
317
318 // from compile_time_features.hpp
319 namespace compile_time
320 {
321 using namespace libdar::compile_time;
322 }
323
324 // from fichier_local.hpp
326
327 // from mycurl_protocol.hpp
329 constexpr mycurl_protocol proto_ftp = mycurl_protocol::proto_ftp;
330 constexpr mycurl_protocol proto_sftp = mycurl_protocol::proto_sftp;
331
332 inline mycurl_protocol string_to_mycurl_protocol(const std::string & arg) { return libdar::string_to_mycurl_protocol(arg); }
333
334 // from memory_file.hpp
336
337 // from entrepot_local
339
340 // from datetime
341 using libdar::datetime;
342
343 // from tuyau
344 using libdar::tuyau;
345
346 // from archive_aux.hpp
349 constexpr comparison_fields cf_all = comparison_fields::all;
350 constexpr comparison_fields cf_ignore_owner = comparison_fields::ignore_owner;
351 constexpr comparison_fields cf_mtime = comparison_fields::mtime;
352 constexpr comparison_fields cf_inode_type = comparison_fields::inode_type;
353
360
362 // LIBDAR INITIALIZATION METHODS //
363 // //
364 // A FUNCTION OF THE get_version*() FAMILY *MUST* BE CALLED //
365 // BEFORE ANY OTHER FUNCTION OF THIS LIBRARY //
366 // //
367 // CLIENT PROGRAM MUST CHECK THAT THE MAJOR NUMBER RETURNED //
368 // BY THIS CALL IS NOT GREATER THAN THE VERSION USED AT COMPILATION //
369 // TIME. IF SO, THE PROGRAM MUST ABORT AND RETURN A WARNING TO THE //
370 // USER TELLING THE DYNAMICALLY LINKED VERSION IS TOO RECENT AND NOT //
371 // COMPATIBLE WITH THIS SOFTWARE. THE MESSAGE MUST INVITE THE USER //
372 // TO UPGRADE HIS SOFTWARE WITH A MORE RECENT VERSION COMPATIBLE WITH //
373 // THIS LIBDAR RELEASE. //
375
377
386 extern void get_version(U_I & major, U_I & medium, U_I & minor, bool init_libgcrypt = true);
387
389
401 extern void get_version_noexcept(U_I & major, U_I & medium, U_I & minor, U_16 & exception, std::string & except_msg, bool init_libgcrypt = true);
402
403
404
406 // CLOSING/CLEANING LIBDAR //
408
409 // while libdar has only a single boolean as global variable
410 // that defines whether the library is initialized or not
411 // it must proceed to mutex, and dependent libraries initializations
412 // (liblzo, libgcrypt, etc.), which is done during the get_version() call
413 // Some library also need to clear some data so the following call
414 // is provided in that aim and must be called when libdar will no more
415 // be used by the application.
416
417 extern void close_and_clean();
418
419
421 // WRAPPER FUNCTIONS AROUND archive class methods to trap exceptions and convert them in error code and message
422 // these are intended for C program/programmers not enough confident with C++.
423 //
424 // FOR LIBDAR C++ APPLICATIONS, YOU WOULD RATHER USE THE archive C++ CLASS THAN THESE FOLLOWING WRAPPERS
425 //
427
428
430
435 const path & chem, const std::string & basename,
436 const std::string & extension,
437 const archive_options_read & options,
438 U_16 & exception,
439 std::string & except_msg);
440
441
443
448 const path & fs_root,
449 const path & sauv_path,
450 const std::string & filename,
451 const std::string & extension,
452 const archive_options_create & options,
453 statistics * progressive_report,
454 U_16 & exception,
455 std::string & except_msg);
456
457
458
460
465 archive *ptr,
466 const path &sauv_path,
467 const std::string & filename,
468 const std::string & extension,
469 const archive_options_isolate & options,
470 U_16 & exception,
471 std::string & except_msg);
472
474
479 const path & sauv_path,
480 archive *ref_arch1,
481 const std::string & filename,
482 const std::string & extension,
483 const archive_options_merge & options,
484 statistics * progressive_report,
485 U_16 & exception,
486 std::string & except_msg);
487
488
490
495 U_16 & exception,
496 std::string & except_msg);
497
498
500
505 archive *ptr,
506 const path &fs_root,
507 const archive_options_extract & options,
508 statistics * progressive_report,
509 U_16 & exception,
510 std::string & except_msg);
511
512
514
519 archive *ptr,
520 const archive_options_listing & options,
521 U_16 & exception,
522 std::string & except_msg);
523
524
526
531 archive *ptr,
532 const path & fs_root,
533 const archive_options_diff & options,
534 statistics * progressive_report,
535 U_16 & exception,
536 std::string & except_msg);
537
538
540
545 archive *ptr,
546 const archive_options_test & options,
547 statistics * progressive_report,
548 U_16 & exception,
549 std::string & except_msg);
550
551
553
558 archive *ptr,
559 const std::string & dir,
560 U_16 & exception,
561 std::string & except_msg);
562
563
564
566 // TOOLS ROUTINES //
568
569
571
581 extern char *libdar_str2charptr_noexcept(const std::string & x, U_16 & exception, std::string & except_msg);
582
584 // THREAD CANCELLATION ROUTINES //
586
587#if MUTEX_WORKS
589
595 extern void cancel_thread(pthread_t tid, bool immediate = true, U_64 flag = 0);
596
598
601 extern bool cancel_status(pthread_t tid);
602
604
608 extern bool cancel_clear(pthread_t tid);
609#endif
610
611
613
614} // end of namespace
615
616#endif
API v5 backward compatible class archive.
set of datastructures used to interact with a catalogue object
provide information about current thread (underlying using the widthdrawn POSIX.1e API)
the archive class realizes the most general operations on archives
Definition: archive5.hpp:55
This is a pure virtual class that is used by libdar when interaction with the user is required.
exception used to signal a bug. A bug is triggered when reaching some code that should never be reach...
Definition: erreurs.hpp:163
exception used when a requested fearture has not beed activated at compilation time
Definition: erreurs.hpp:366
exception used when an error concerning the treated data has been met
Definition: erreurs.hpp:312
exception used to signal convertion problem between infinint and string (decimal representation)
Definition: erreurs.hpp:239
exception used when a requested feature is not (yet) implemented
Definition: erreurs.hpp:257
this is the parent class of all exception classes.
Definition: erreurs.hpp:52
exception used when hardware problem is found
Definition: erreurs.hpp:275
exception used when arithmetic error is detected when operating on infinint
Definition: erreurs.hpp:184
exception used to signal an error in the argument given to libdar call of the API
Definition: erreurs.hpp:348
exception used when a limitint overflow is detected, the maximum value of the limitint has been excee...
Definition: erreurs.hpp:202
exception used when memory has been exhausted
Definition: erreurs.hpp:127
exception used to signal range error
Definition: erreurs.hpp:220
exception used when error the inter-slice user command returned an error code
Definition: erreurs.hpp:330
exception used when secure memory has been exhausted
Definition: erreurs.hpp:144
exception used to carry system error
Definition: erreurs.hpp:406
exception used when the thread libdar is running in is asked to stop
Definition: erreurs.hpp:383
exception used to signal that the user has aborted the operation
Definition: erreurs.hpp:293
class archive_num stores the position of an archive inside a dar_manager database
Definition: archive_num.hpp:47
class holding optional parameters used to create an archive
class holding optional parameters used to extract files from an existing archive
class holding optional parameters used to isolate an existing archive
class holding optional parameters used to list the contents of an existing archive
class holding optional parameters used to proceed to the merge operation
class holding optional parameters used to read an existing archive
class holding optional parameters used to test the structure coherence of an existing archive
boolean mask, either always true or false
Definition: mask.hpp:101
the global action for overwriting
Definition: crit_action.hpp:81
realises the AND operator
Definition: criterium.hpp:507
the crit_chain class sequences crit_actions up to full definition of the action
the basic constant action
returns true if the space used by EA of the first entry is greater or equal to the space used by the ...
Definition: criterium.hpp:428
returns true if the EA of the first entry is more recent or equal to the fixed date given in argument...
Definition: criterium.hpp:385
returns true if the EA of the first entry is more recent or equal to the one of the second entry
Definition: criterium.hpp:361
returns true if the in place entry has its EA saved (not just marked as saved) in the archve of refer...
Definition: criterium.hpp:447
returns true if the data of the first entry is bigger or equal to the one of the second entry
Definition: criterium.hpp:224
return true if the entry is a dirty file (or hard linked dirty file)
Definition: criterium.hpp:262
If the in_place entry is not an inode its date is considered equal to zero. Comparison is done on mti...
Definition: criterium.hpp:201
returns true if the data of the first entry is more recent or of the same date of the one of the seco...
Definition: criterium.hpp:177
if the entry is not an inode the result is also true
Definition: criterium.hpp:245
return true if the entry is a sparse file (or hard linked sparse file)
Definition: criterium.hpp:278
return true if the entry has delta signature
Definition: criterium.hpp:295
returns true if the first entry is a cat_directory (whatever is the second)
Definition: criterium.hpp:104
returns true if the first entry is a plain file (whatever is the second)
Definition: criterium.hpp:121
returns true if the first entry is a inode with several hard links (whatever is the second entry)
Definition: criterium.hpp:139
returns true if the first entry is an inode (whatever is the second)
Definition: criterium.hpp:87
returns true if the first entry has more or even EA (in number not in size) than the second entry
Definition: criterium.hpp:408
realises the negation of the criterium given in argument to its constructor
Definition: criterium.hpp:484
returns true if the two entries are of the same type (plain-file/char dev/block dev/named pipe/symlin...
Definition: criterium.hpp:467
the generic criterium class, parent of all criterium
Definition: criterium.hpp:52
stores time information
Definition: datetime.hpp:59
decimal class, convert infinint from and to decimal represention
Definition: deci.hpp:51
makes an AND operator between two or more masks
Definition: mask.hpp:273
matches if string is the given constructor string or a sub directory of it
Definition: mask.hpp:458
filesystem local files
this is the interface class from which all other data transfer classes inherit
the arbitrary large positive integer class
Definition: list_entry.hpp:60
the mask_list class, matches string that are present in a given file
Definition: mask_list.hpp:51
the generic class, parent of all masks
Definition: mask.hpp:62
generic_file stored in memory
Definition: memory_file.hpp:41
negation of another mask
Definition: mask.hpp:227
makes the OR operator between two or more masks
Definition: mask.hpp:360
the class path is here to manipulate paths in the Unix notation: using'/'
Definition: path.hpp:51
matches regular expressions (see "man 7 regex")
Definition: mask.hpp:174
matches if string is exactly the given mask (no wilde card expression)
Definition: mask.hpp:427
class secu_string
Definition: secu_string.hpp:54
matches as done on shell command lines (see "man 7 glob")
Definition: mask.hpp:131
string matches if it is subdir of mask or mask is a subdir of expression
Definition: mask.hpp:396
class used by libdar::archive class to give a summary of treated file during and after an operation
Definition: statistics.hpp:70
the testing class binds criterium to actions
class to be used as parent to provide checkpoints to inherited classes
pipe implementation under the generic_file interface.
Definition: tuyau.hpp:49
nested namespace containing routines that give features activated at compile time
compression engine implementation
the crypto algoritm definition
base classes used to store entree information in dar_manager databases
this file holds the database class definition as defined in API version 5
manages the decimal representation of infinint
defines the implementation for remote filesystem entrepot using libcurl
defines the implementation for local filesystem entrepot The entrepot_local correspond to the local f...
class fichier_local definition. This is a full implementation/inherited class of class fichier_global...
void 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)
const U_I LIBDAR_COMPILE_TIME_MINOR
libdar Minor version defined at compilation time
Definition: libdar5.hpp:359
archive * 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
char * libdar_str2charptr_noexcept(const std::string &x, U_16 &exception, std::string &except_msg)
routine provided to convert std::string to char *
bool 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
statistics 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
archive * 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
void 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
statistics 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
const U_I LIBDAR_COMPILE_TIME_MAJOR
libdar Major version defined at compilation time
Definition: libdar5.hpp:355
const U_I LIBDAR_COMPILE_TIME_MEDIUM
libdar Medium version defined at compilation time
Definition: libdar5.hpp:357
archive * 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
statistics 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
void close_archive_noexcept(archive *ptr, U_16 &exception, std::string &except_msg)
this is wrapper around the archive destructor
archive * 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
void 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)
modified_data_detection
how to detect data has changed when some fields
Definition: archive_aux.hpp:44
comparison_fields
how to consider file change during comparison and incremental backup
Definition: archive_aux.hpp:53
std::string compression2string(compression c)
convert a compression to its string representation
over_action_ea
the possible action for overwriting EA
Definition: crit_action.hpp:62
char compression2char(compression c, bool per_block=false)
convert a compression value to a char for storing in archive
fsa_scope all_fsa_families()
provides a scope containing all FSA families
std::set< fsa_family > fsa_scope
set of fsa families
Definition: fsa_family.hpp:70
compression char2compression(char a)
convert a char as stored in archive to its compression value
mycurl_protocol
libcurl protocols supported by libdar
hash_algo
hashing algorithm available
Definition: archive_aux.hpp:63
compression string2compression(const std::string &a)
convert a string representing a compression algorithm to its enum compression value
compression
the different compression algorithm available
Definition: compression.hpp:46
crypto_algo
the different cypher available for encryption (strong or weak)
Definition: crypto.hpp:50
mycurl_protocol string_to_mycurl_protocol(const std::string &arg)
extract mycurl_protocol from a given URL
fsa_family
FSA family.
Definition: fsa_family.hpp:42
over_action_data
the possible actions for overwriting data
Definition: crit_action.hpp:47
fsa_nature
FSA nature.
Definition: fsa_family.hpp:48
capa_status
the EFFECTIVE set the value of the associated capability for the calling thread
infinint tools_get_extended_size(std::string s, U_I base)
convert the given string to infinint taking care of multiplication suffixes like k,...
std::string tools_getcwd()
get current working directory
U_I tools_octal2int(const std::string &perm)
convert octal string to integer
std::string tools_printf(const char *format,...)
make printf-like formating to a std::string
gf_mode
generic_file openning modes
Definition: gf_mode.hpp:44
bool tools_my_atoi(const char *a, U_I &val)
ascii to integer conversion
switch module to limitint (32 ou 64 bits integers) or infinint
are defined here basic integer types that tend to be portable
here lies a collection of mask classes
here lies a mask that selects files present in a given list
libdar5 namespace encapsulate all libdar symbols
Definition: archive5.hpp:37
nested namespace inside libdar
here is the definition of the path class
class handling access to the data summary of treated files after and during each operation
holds the statistics contents of a catalogue
signator status
Definition: crypto.hpp:63
to be able to cancel libdar operation while running in a given thread.
a set of general purpose routines
defines the implementation of pipe under the generic_file interface.
defines the interaction interface between libdar and users.
API v5 backward compatible user_interaction_callback class.