Disk ARchive  2.7.2
Full featured and portable backup and archiving tool
compress_block_header.hpp
Go to the documentation of this file.
1 /*********************************************************************/
2 // dar - disk archive - a backup/restoration program
3 // Copyright (C) 2002-2021 Denis Corbin
4 //
5 // This program is free software; you can redistribute it and/or
6 // modify it under the terms of the GNU General Public License
7 // as published by the Free Software Foundation; either version 2
8 // of the License, or (at your option) any later version.
9 //
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
14 //
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software
17 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 //
19 // to contact the author, see the AUTHOR file
20 /*********************************************************************/
21 
25 
26 #ifndef COMPRESS_BLOCK_HEADER_HPP
27 #define COMPRESS_BLOCK_HEADER_HPP
28 
29 #include "../my_config.h"
30 #include "infinint.hpp"
31 #include "generic_file.hpp"
32 
33 
34 namespace libdar
35 {
36 
39 
41 
43  {
44  // type values
45  static constexpr const char H_DATA = 1;
46  static constexpr const char H_EOF = 2;
47 
48  // fields
49 
50  char type;
52 
53  void dump(generic_file & f);
54 
56 
60  bool set_from(generic_file & f);
61  };
62 
63 
65 
66 } // end of namespace
67 
68 #endif
libdar::compress_block_header::size
infinint size
size of the following compressed block of data
Definition: compress_block_header.hpp:51
infinint.hpp
switch module to limitint (32 ou 64 bits integers) or infinint
libdar::infinint
the arbitrary large positive integer class
Definition: real_infinint.hpp:61
libdar::compress_block_header
block header structure used for storing compressed blocks
Definition: compress_block_header.hpp:42
generic_file.hpp
class generic_file is defined here as well as class fichier
libdar::generic_file
this is the interface class from which all other data transfer classes inherit
Definition: generic_file.hpp:76
libdar::compress_block_header::type
char type
let the possibility to extend this architecture (for now type is fixed)
Definition: compress_block_header.hpp:50
libdar::compress_block_header::set_from
bool set_from(generic_file &f)
read the block header from a generic_file (an archive)
libdar
libdar namespace encapsulate all libdar symbols
Definition: archive.hpp:46