26 #ifndef MEMORY_FILE_HPP
27 #define MEMORY_FILE_HPP
38 class memory_file :
public generic_file
47 void reset() {
if(
is_terminated())
throw SRC_BUG; position = 0; data = storage(0); };
48 infinint size()
const {
return data.size(); };
52 bool skippable(skippability direction,
const infinint & amount) {
return true; };
53 bool skip(
const infinint & pos);
55 bool skip_relative(S_I x);
56 infinint get_position()
const {
if(
is_terminated())
throw SRC_BUG;
return position; };
62 void inherited_read_ahead(
const infinint & amount) {};
63 U_I inherited_read(
char *a, U_I size);
64 void inherited_write(
const char *a, U_I size);
65 void inherited_sync_write() {};
66 void inherited_flush_read() {};
67 void inherited_terminate() {};
class generic_file is defined here as well as class fichierthe generic_file interface is widely used ...
contains a class that permits arbitrary large data storage
bool is_terminated() const
generic_file(gf_mode m)
main constructor
libdar namespace encapsulate all libdar symbols