29 #include "../my_config.h"
73 const std::string & base_name,
74 const std::string & extension,
79 const std::string & execute =
"");
106 const std::string & base_name,
107 const std::string & extension,
110 bool x_warn_overwrite,
111 bool x_allow_overwrite,
114 const label & internal_name,
115 const label & data_name,
116 bool force_permission,
120 bool format_07_compatible,
121 const std::string & execute =
"");
138 const slice_layout & get_slicing()
const {
return slicing; };
139 bool get_total_file_number(infinint &num)
const { num = of_last_file_num;
return of_last_file_known; };
140 bool get_last_file_size(infinint &num)
const { num = of_last_file_size;
return of_last_file_known; };
143 void disable_natural_destruction() { natural_destruction =
false; };
146 void enable_natural_destruction() { natural_destruction =
true; };
149 bool is_an_old_start_end_archive()
const {
return slicing.older_sar_than_v8; };
152 const label & get_internal_name_used()
const {
return of_internal_name; };
155 const label & get_data_name()
const {
return of_data_name; };
157 const entrepot *get_entrepot()
const {
return entr; };
172 slice_layout slicing;
176 bool natural_destruction;
182 bool of_last_file_known;
185 label of_internal_name;
189 fichier_global *of_fd;
193 bool opt_warn_overwrite;
194 bool opt_allow_overwrite;
200 bool skip_forward(U_I x);
201 bool skip_backward(U_I x);
202 void close_file(
bool terminal);
203 void open_readonly(
const std::string & fic,
const infinint &num);
204 void open_writeonly(
const std::string & fic,
const infinint &num);
205 void open_file_init();
208 void open_last_file();
209 bool is_current_eof_a_normal_end_of_slice()
const;
210 infinint bytes_still_to_read_in_slice()
const;
214 void hook_execute(
const infinint &num);
void inherited_flush_read()
defines the entrepot interface. Entrepot interface defines a generic way to interact with files (slic...
sar(const sar &ref)
the destructor
are defined here basic integer types that tend to be portable
bool skip_to_eof()
skip to the end of file
class generic_file is defined here as well as class fichierthe generic_file interface is widely used ...
void inherited_sync_write()
write down any pending data
This is a pure virtual class that is used by libdar when interaction with the user is required...
Sar class stands for Segmentation And Reassembly class.
U_I inherited_read(char *a, U_I size)
implementation of read() operation
gf_mode
generic_file openning modes
object describing the slicing of an archive
void inherited_read_ahead(const infinint &amount)
bool skippable(skippability direction, const infinint &amount)
here is the definition of the path classthe path class handle path and provide several operation on t...
exception used when a requested feature is not (yet) implemented
void inherited_terminate()
destructor-like call, except that it is allowed to throw exceptions
switch module to limitint (32 ou 64 bits integers) or infinint
this is the interface class from which all other data transfer classes inherit
class mem_ui to keep a copy of a user_interaction object
bool skip(const infinint &pos)
void inherited_write(const char *a, U_I size)
implementation of the write() operation
the arbitrary large positive integer class
bool skip_relative(S_I x)
skip relatively to the current position
sar(const user_interaction &dialog, const std::string &base_name, const std::string &extension, const entrepot &where, bool by_the_end, const infinint &x_min_digits, bool lax=false, const std::string &execute="")
this constructor reads data from a set of slices
libdar namespace encapsulate all libdar symbols
infinint get_position() const
get the current read/write position