Loading...
Searching...
No Matches
filtre.hpp
Go to the documentation of this file.
/*********************************************************************/
// dar - disk archive - a backup/restoration program
// Copyright (C) 2002-2024 Denis Corbin
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
//
// to contact the author, see the AUTHOR file
/*********************************************************************/
#ifndef FILTRE_HPP
#define FILTRE_HPP
#include "../my_config.h"
#include "mask.hpp"
#include "pile.hpp"
#include "catalogue.hpp"
#include "path.hpp"
#include "statistics.hpp"
#include "archive_options.hpp"
#include "thread_cancellation.hpp"
#include "filesystem_ids.hpp"
namespace libdar
{
extern void filtre_restore(const std::shared_ptr<user_interaction> & dialog,
const mask &filtre,
const mask & subtree,
const catalogue & cat,
const path & fs_racine,
bool fs_warn_overwrite,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
bool display_skipped,
statistics & st,
const mask & ea_mask,
bool flat,
comparison_fields what_to_check,
bool warn_remove_no_match,
bool empty,
bool empty_dir,
const crit_action & x_overwrite,
archive_options_extract::t_dirty dirty,
bool only_deleted,
bool not_deleted,
const fsa_scope & scope,
bool ignore_unix_sockets
);
extern void filtre_sauvegarde(const std::shared_ptr<user_interaction> & dialog,
const mask &filtre,
const mask &subtree,
const pile_descriptor & pdesc,
catalogue & cat,
const catalogue & ref,
const path & fs_racine,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
bool display_skipped,
bool display_finished,
statistics & st,
bool make_empty_dir,
const mask & ea_mask,
const mask &compr_mask,
const infinint & min_compr_size,
bool nodump,
const infinint & hourshift,
bool alter_time,
bool furtive_read_mode,
const filesystem_ids & same_fs,
comparison_fields what_to_check,
bool snapshot,
bool cache_directory_tagging,
bool security_check,
const infinint & repeat_count,
const infinint & repeat_byte,
const infinint & fixed_date,
const infinint & sparse_file_min_size,
const std::string & backup_hook_file_execute,
const mask & backup_hook_file_mask,
bool ignore_unknown,
const fsa_scope & scope,
const std::string & exclude_by_ea,
bool delta_signature, // whether to compute delta sig file on the saved file
const infinint & delta_sig_min_size, // size below which to never calculate delta sig
const mask & delta_mask, // mask defining for which file to calculate delta sig
bool delta_diff, // whether to perform delta diff backup when delta sig is present
bool auto_zeroing_neg_dates,
const std::set<std::string> & ignored_symlinks,
modified_data_detection mod_data_detect,
const delta_sig_block_size & delta_sig_block_len);
extern void filtre_difference(const std::shared_ptr<user_interaction> & dialog,
const mask &filtre,
const mask &subtree,
const catalogue & cat,
const path & fs_racine,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
bool display_skipped,
statistics & st,
const mask & ea_mask,
bool alter_time,
bool furtive_read_mode,
comparison_fields what_to_check,
const infinint & hourshift,
bool compare_symlink_date,
const fsa_scope & scope,
bool isolated_mode);
extern void filtre_test(const std::shared_ptr<user_interaction> & dialog,
const mask &filtre,
const mask &subtree,
const catalogue & cat,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
bool display_skipped,
bool empty,
statistics & st);
extern void filtre_merge(const std::shared_ptr<user_interaction> & dialog,
const mask & filtre,
const mask & subtree,
const pile_descriptor & pdesc,
catalogue & cat,
const catalogue * ref1,
const catalogue * ref2,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
bool display_skipped,
statistics & st,
bool make_empty_dir,
const mask & ea_mask,
const mask & compr_mask,
const infinint & min_compr_size,
bool keep_compressed,
const crit_action & overwrite,
bool warn_overwrite,
bool decremental_mode,
const infinint & sparse_file_min_size,
const fsa_scope & scope,
bool delta_signature,
bool build_delta_sig,
const infinint & delta_sig_min_size,
const mask & delta_mask,
const delta_sig_block_size & signature_block_size);
extern void filtre_merge_step0(const std::shared_ptr<user_interaction> & dialog,
const catalogue * ref1,
const catalogue * ref2,
statistics & st,
bool decremental_mode,
crit_action* & decr,
const crit_action* & overwrite,
bool & abort,
thread_cancellation & thr_cancel);
extern void filtre_merge_step1(const std::shared_ptr<user_interaction> & dialog,
const mask & filtre,
const mask & subtree,
catalogue & cat,
const catalogue * ref1,
const catalogue * ref2,
bool info_details,
bool display_treated,
bool display_skipped,
statistics & st,
bool make_empty_dir,
bool warn_overwrite,
bool decremental_mode,
crit_action* & decr,
const crit_action* & overwrite,
bool & abort,
thread_cancellation & thr_cancel);
extern void filtre_merge_step2(const std::shared_ptr<user_interaction> & dialog,
const pile_descriptor & pdesc,
catalogue & cat,
bool info_details,
bool display_treated,
bool display_treated_only_dir,
const mask & compr_mask,
const infinint & min_compr_size,
bool keep_compressed,
const infinint & sparse_file_min_size,
bool delta_signature,
bool build_delta_sig,
const infinint & delta_sig_min_size,
const mask & delta_mask,
bool & abort,
thread_cancellation & thr_cancel,
bool repair_mode,
const delta_sig_block_size & signature_block_size);
void filtre_sequentially_read_all_catalogue(catalogue & cat,
const std::shared_ptr<user_interaction> & dialog,
bool lax_read_mode);
} // end of namespace
#endif
archive_options.hpp
this file contains a set of classes used to transmit options to archive operation
catalogue.hpp
here is defined the classe used to manage catalogue of archives
libdar::catalogue
the catalogue class which gather all objects contained in a give archive
Definition catalogue.hpp:60
libdar::crit_action
the global action for overwriting
Definition crit_action.hpp:81
libdar::infinint
the arbitrary large positive integer class
Definition real_infinint.hpp:62
libdar::mask
the generic class, parent of all masks
Definition mask.hpp:62
libdar::path
the class path is here to manipulate paths in the Unix notation: using'/'
Definition path.hpp:51
libdar::statistics
class used by libdar::archive class to give a summary of treated file during and after an operation
Definition statistics.hpp:70
libdar::thread_cancellation
class to be used as parent to provide checkpoints to inherited classes
Definition thread_cancellation.hpp:69
filesystem_ids.hpp
gather the ids of different filesystem to provide a filter based on filesystem
libdar::modified_data_detection
modified_data_detection
how to detect data has changed when some fields
Definition archive_aux.hpp:44
libdar::comparison_fields
comparison_fields
how to consider file change during comparison and incremental backup
Definition archive_aux.hpp:53
libdar::fsa_scope
std::set< fsa_family > fsa_scope
set of fsa families
Definition fsa_family.hpp:70
libdar::filtre_merge_step0
void filtre_merge_step0(const std::shared_ptr< user_interaction > &dialog, const catalogue *ref1, const catalogue *ref2, statistics &st, bool decremental_mode, crit_action *&decr, const crit_action *&overwrite, bool &abort, thread_cancellation &thr_cancel)
initialize variables used for merging in step1 and step2
libdar::filtre_merge_step2
void filtre_merge_step2(const std::shared_ptr< user_interaction > &dialog, const pile_descriptor &pdesc, catalogue &cat, bool info_details, bool display_treated, bool display_treated_only_dir, const mask &compr_mask, const infinint &min_compr_size, bool keep_compressed, const infinint &sparse_file_min_size, bool delta_signature, bool build_delta_sig, const infinint &delta_sig_min_size, const mask &delta_mask, bool &abort, thread_cancellation &thr_cancel, bool repair_mode, const delta_sig_block_size &signature_block_size)
copies data of "cat" catalogue to the pdesc of a brand new archive
libdar::filtre_merge_step1
void filtre_merge_step1(const std::shared_ptr< user_interaction > &dialog, const mask &filtre, const mask &subtree, catalogue &cat, const catalogue *ref1, const catalogue *ref2, bool info_details, bool display_treated, bool display_skipped, statistics &st, bool make_empty_dir, bool warn_overwrite, bool decremental_mode, crit_action *&decr, const crit_action *&overwrite, bool &abort, thread_cancellation &thr_cancel)
builds a catalogue from two refs with the given policy and filters
libdar::filtre_restore
void filtre_restore(const std::shared_ptr< user_interaction > &dialog, const mask &filtre, const mask &subtree, const catalogue &cat, const path &fs_racine, bool fs_warn_overwrite, bool info_details, bool display_treated, bool display_treated_only_dir, bool display_skipped, statistics &st, const mask &ea_mask, bool flat, comparison_fields what_to_check, bool warn_remove_no_match, bool empty, bool empty_dir, const crit_action &x_overwrite, archive_options_extract::t_dirty dirty, bool only_deleted, bool not_deleted, const fsa_scope &scope, bool ignore_unix_sockets)
mask.hpp
here lies a collection of mask classes
libdar
libdar namespace encapsulate all libdar symbols
Definition archive.hpp:47
path.hpp
here is the definition of the path class
pile.hpp
class pile definition. Used to manage a stack of generic_file objects
statistics.hpp
class handling access to the data summary of treated files after and during each operation
libdar::delta_sig_block_size
defines how to calculate delta signature block size based of file size to delta sign
Definition delta_sig_block_size.hpp:47
thread_cancellation.hpp
to be able to cancel libdar operation while running in a given thread.