![]()  | 
  
    Disk ARchive 2.8.1
    
   Full featured and portable backup and archiving tool 
   | 
 
the class i_database is the implementation of class database More...
#include <i_database.hpp>
 Inheritance diagram for libdar::database::i_database:
 Collaboration diagram for libdar::database::i_database:Classes | |
| struct | archive_data | 
| holds the archive used to create the database  More... | |
Public Member Functions | |
| i_database (const std::shared_ptr< user_interaction > &dialog) | |
| this constructor build an empty database  | |
| i_database (const std::shared_ptr< user_interaction > &dialog, const std::string &base, const database_open_options &opt) | |
| this constructor reads i_database from a file  | |
| i_database (const i_database &ref)=delete | |
| disabling copy constructor  | |
| i_database (i_database &&ref) noexcept=delete | |
| disabling move constructor  | |
| i_database & | operator= (const i_database &ref)=delete | 
| disabling assignement operator  | |
| i_database & | operator= (i_database &&ref) noexcept=delete | 
| disabling move assignment operator  | |
| ~i_database () | |
| i_database destructor (no implicit file saving)  | |
| void | dump (const std::string &filename, const database_dump_options &opt) const | 
| write the database to a file (see database_header first)  | |
| void | add_archive (const archive &arch, const std::string &chemin, const std::string &basename, const database_add_options &opt) | 
| add an archive to the database  | |
| void | remove_archive (archive_num min, archive_num max, const database_remove_options &opt) | 
| remove an archive from a database  | |
| void | set_permutation (archive_num src, archive_num dst) | 
| change order of archive within the database  | |
| void | change_name (archive_num num, const std::string &basename, const database_change_basename_options &opt) | 
| change one's archive basename recorded in the database  | |
| void | set_path (archive_num num, const std::string &chemin, const database_change_path_options &opt) | 
| change one's archive path recorded in the database  | |
| void | set_options (const std::vector< std::string > &opt) | 
| change the default options given to dar when performing restoration  More... | |
| void | set_dar_path (const std::string &chemin) | 
| change the path to dar command  More... | |
| void | set_compression (compression algozip) const | 
| change compression to use when storing base on file  More... | |
| void | set_compression_level (U_I level) const | 
| change the compression level to use when storing base in file  More... | |
| database_archives_list | get_contents () const | 
| provides the list of archive used to build the database  | |
| std::vector< std::string > | get_options () const | 
| return the options used with dar for restoration  More... | |
| std::string | get_dar_path () const | 
| returns the path for dar  More... | |
| compression | get_compression () const | 
| returns the compression algorithm used on filesystem  More... | |
| U_I | get_compression_level () const | 
| returns the compression level used on file  More... | |
| std::string | get_database_version () const | 
| return the database format version  More... | |
| void | get_files (database_listing_show_files_callback callback, void *context, archive_num num, const database_used_options &opt) const | 
| list files which are present in a given archive  | |
| void | get_version (database_listing_get_version_callback callback, void *context, path chemin) const | 
| list the archive where a give file is present  | |
| void | show_most_recent_stats (database_listing_statistics_callback callback, void *context) const | 
| compute some statistics about the location of most recent file versions  | |
| void | restore (const std::vector< std::string > &filename, const database_restore_options &opt) | 
| restore files calling dar on the appropriated archive  | |
| void | restore (const archive_options_read &read_options, const path &fs_root, archive_options_extract extract_options, const database_restore_options &opt, statistics *progressive_report) | 
| restore files calling libdar directly rather than spawning dar CLI and parsing options as CLI  | |
| bool | check_order () const | 
| check that all files's Data and EA are more recent when archive number grows within the database, only warn the user  More... | |
  Public Member Functions inherited from libdar::mem_ui | |
| mem_ui (const std::shared_ptr< user_interaction > &dialog) | |
| constructor  More... | |
| mem_ui (const mem_ui &ref)=default | |
| the copy constructor  More... | |
| mem_ui (mem_ui &&ref) noexcept=default | |
| the move constructor  | |
| mem_ui & | operator= (const mem_ui &ref)=default | 
| assignement operator  More... | |
| mem_ui & | operator= (mem_ui &&ref) noexcept=default | 
| move operator  | |
| virtual | ~mem_ui () noexcept(false) | 
| destructor  More... | |
Private Member Functions | |
| void | build (generic_file &f, bool partial, bool read_only, unsigned char db_version) | 
| used by constructors  | |
| archive_num | get_real_archive_num (archive_num num, bool revert) const | 
| const datetime & | get_root_last_mod (const archive_num &num) const | 
Private Attributes | |
| std::deque< struct archive_data > | coordinate | 
| list of archive used to build the database  More... | |
| std::vector< std::string > | options_to_dar | 
| options to use when calling dar for restoration  More... | |
| std::string | dar_path | 
| path to dar  More... | |
| data_dir * | files | 
| structure containing files and their status in the set of archive used for that database (is set to nullptr in partial mode)  More... | |
| storage * | data_files | 
| when reading archive in partial mode, this is where is located the "not readed" part of the archive (is set to nullptr in partial-read-only mode)  More... | |
| bool | check_order_asked | 
| whether order check has been asked  More... | |
| unsigned char | cur_db_version | 
| current db version (for informational purposes)  More... | |
| compression | algo | 
| compression used/to use when writing down the base to file  More... | |
| U_I | compr_level | 
| the compression level to use  More... | |
Additional Inherited Members | |
  Protected Member Functions inherited from libdar::mem_ui | |
| user_interaction & | get_ui () const | 
| get access to the user_interaction object  More... | |
| std::shared_ptr< user_interaction > | get_pointer () const | 
| get access to the shared_ptr pointing to the user_interaction  More... | |
| void | change_ui (const std::shared_ptr< user_interaction > &new_dialog) | 
| change the user_interaction object  More... | |
the class i_database is the implementation of class database
Definition at line 54 of file i_database.hpp.
      
  | 
  inline | 
check that all files's Data and EA are more recent when archive number grows within the database, only warn the user
Definition at line 165 of file i_database.hpp.
References files.
      
  | 
  inline | 
returns the compression algorithm used on filesystem
Definition at line 127 of file i_database.hpp.
References algo.
      
  | 
  inline | 
returns the compression level used on file
Definition at line 130 of file i_database.hpp.
References compr_level.
      
  | 
  inline | 
      
  | 
  inline | 
return the database format version
Definition at line 133 of file i_database.hpp.
References cur_db_version.
      
  | 
  inline | 
return the options used with dar for restoration
Definition at line 121 of file i_database.hpp.
References options_to_dar.
      
  | 
  inline | 
change compression to use when storing base on file
Definition at line 107 of file i_database.hpp.
References algo.
      
  | 
  inline | 
change the compression level to use when storing base in file
Definition at line 110 of file i_database.hpp.
References compr_level.
      
  | 
  inline | 
      
  | 
  inline | 
change the default options given to dar when performing restoration
Definition at line 101 of file i_database.hpp.
References options_to_dar.
      
  | 
  mutableprivate | 
compression used/to use when writing down the base to file
Definition at line 195 of file i_database.hpp.
Referenced by get_compression(), and set_compression().
      
  | 
  private | 
whether order check has been asked
Definition at line 193 of file i_database.hpp.
      
  | 
  mutableprivate | 
the compression level to use
Definition at line 196 of file i_database.hpp.
Referenced by get_compression_level(), and set_compression_level().
      
  | 
  private | 
list of archive used to build the database
Definition at line 188 of file i_database.hpp.
      
  | 
  private | 
current db version (for informational purposes)
Definition at line 194 of file i_database.hpp.
Referenced by get_database_version().
      
  | 
  private | 
path to dar
Definition at line 190 of file i_database.hpp.
Referenced by get_dar_path(), and set_dar_path().
      
  | 
  private | 
when reading archive in partial mode, this is where is located the "not readed" part of the archive (is set to nullptr in partial-read-only mode)
Definition at line 192 of file i_database.hpp.
      
  | 
  private | 
structure containing files and their status in the set of archive used for that database (is set to nullptr in partial mode)
Definition at line 191 of file i_database.hpp.
Referenced by check_order().
      
  | 
  private | 
options to use when calling dar for restoration
Definition at line 189 of file i_database.hpp.
Referenced by get_options(), and set_options().