32 #ifndef FILESYSTEM_HPP 33 #define FILESYSTEM_HPP 35 #include "../my_config.h" 72 bool x_furtive_read_mode,
73 const fsa_scope & scope) :
mem_ui(&dialog)
74 { furtive_read_mode = x_furtive_read_mode; sc = scope; ask_before_zeroing_neg_dates =
true; };
84 const infinint & get_last_etoile_ref()
const {
return etiquette_counter; };
96 void corres_reset() { corres_read.clear(); etiquette_counter = 0; };
102 const std::string & name,
104 const mask & ea_mask);
106 bool get_ask_before_zeroing_neg_dates()
const {
return ask_before_zeroing_neg_dates; };
117 couple(
cat_etoile *ptr, nlink_t ino_count) : holder(
"FAKE", ptr) { count = ino_count; obj = ptr; };
122 node(ino_t num, dev_t dev) { numnode = num; device = dev; };
125 bool operator < (
const node & ref)
const {
return numnode < ref.numnode || (numnode == ref.numnode && device < ref.device); };
132 std::map <node, couple> corres_read;
134 bool furtive_read_mode;
136 bool ask_before_zeroing_neg_dates;
150 const mask & x_ea_mask,
151 bool check_no_dump_flag,
153 bool furtive_read_mode,
154 bool x_cache_directory_tagging,
156 bool x_ignore_unknown,
157 const fsa_scope & scope);
162 void reset_read(
infinint & root_fs_device);
164 void skip_read_to_parent_dir();
174 bool furtive_read_mode;
175 bool cache_directory_tagging;
177 std::vector<etage> pile;
193 const mask & x_ea_mask,
195 bool furtive_read_mode,
196 const fsa_scope & scope);
202 bool read_filename(
const std::string & name,
cat_nomme * &ref);
206 void skip_read_filename_in_parent_dir();
210 struct filename_struct
220 bool furtive_read_mode;
222 std::vector<filename_struct> filename_pile;
240 void write_hard_linked_target_if_not_set(
const cat_mirage *ref,
const std::string & chemin);
245 bool known_etiquette(
const infinint & eti);
251 void clear_corres_if_pointing_to(
const infinint & ligne,
const std::string &
path);
254 void corres_reset() { corres_write.clear(); };
259 const fsa_scope & scope);
274 const std::string & spot,
275 const mask & ea_mask);
284 bool raw_clear_ea_set(
const cat_nomme *e,
const std::string & path);
294 std::map <infinint, corres_ino_ea> corres_write;
306 bool x_warn_overwrite,
308 const mask & x_ea_mask,
310 bool x_warn_remove_no_match,
313 bool x_only_overwrite,
314 const fsa_scope & scope);
328 done_no_change_no_data,
329 done_no_change_policy,
331 } action_done_for_data;
344 action_done_for_data & data_restored,
348 bool & fsa_restored);
364 bool get_restore_date()
const {
return restore_date; };
365 void set_restore_date(
bool val) { restore_date = val; };
376 bool warn_remove_no_match;
377 std::vector<stack_dir_t> stack_dir;
380 bool ignore_over_restricts;
385 void restore_stack_dir_ownership();
390 void action_over_remove(
const cat_inode *in_place,
392 const std::string & spot,
395 void action_over_data(
const cat_inode *in_place,
397 const std::string & spot,
399 action_done_for_data & data_done);
401 bool action_over_ea(
const cat_inode *in_place,
403 const std::string & spot,
406 bool action_over_fsa(
const cat_inode *in_place,
408 const std::string & spot,
contains classes that let the user define the policy for overwriting files
filesystem specific attributes available families and fsa_scope definition
the generic class, parent of all masks
the hard link implementation (etoile means star in French, seen a star as a point from which are thro...
user_interaction & get_ui() const
get access to the user_interaction cloned object
over_action_data
the possible actions for overwriting data
keep trace of hard links when reading the filesystem
void ignore_overwrite_restrictions_for_next_write()
This is a pure virtual class that is used by libdar when interaction with the user is required...
make a flow sequence of inode to feed the backup filtering routing
over_action_ea
the possible action for overwriting EA
the hard link implementation, cat_mirage is the named entry owned by a directory it points to a commo...
the cat_directory inode class
definition of the etage structure is done here
filesystem_restore(const filesystem_restore &ref)
copy constructor is forbidden (throws an exception)
the global action for overwriting
mem_ui(const user_interaction &dialog)
constructor
the base class for all entry that have a name
switch module to limitint (32 ou 64 bits integers) or infinint
class mem_ui to keep a copy of a user_interaction object
~filesystem_restore()
destructor
make a flow of inode to feed the difference filter routine
this is the base class of object that can be allocated on a memory pool
the root class for all cat_inode
receive the flow of inode from the restoration filtering routing and promotes these to real filesyste...
the arbitrary large positive integer class
void zeroing_negative_dates_without_asking()
don't ask before zeroing negative date just warn user
include file gathering all entree found in a catalogue
the root class from all other inherite for any entry in the catalogue
const fsa_scope get_fsa_scope() const
provide the FSA scope used by the object
libdar namespace encapsulate all libdar symbols
comparison_fields
flag used to only consider certain fields when comparing/restoring inodes
here is defined the many classed which is build of the catalogue
keep trace of already written inodes to restore hard links
the class path is here to manipulate paths in the Unix notation: using'/'