| Disk ARchive 2.6.12 Full featured and portable backup and archiving tool

generic_file_overlay_for_gpgme.hpp
Go to the documentation of this file.
1 //*********************************************************************/
2 // dar - disk archive - a backup/restoration program
3 // Copyright (C) 2002-2020 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 : http://dar.linux.free.fr/email.html
20 /*********************************************************************/
21
25
26 #ifndef GENERIC_FILE_OVERLAY_FOR_GPGME_HPP
27 #define GENERIC_FILE_OVERLAY_FOR_GPGME_HPP
28
29 extern "C"
30 {
31 #if HAVE_GPGME_H
32 #include <gpgme.h>
33 #endif
34 }
35
36 #include "../my_config.h"
37 #include "generic_file.hpp"
38
39 namespace libdar
40 {
43
45
46 class generic_file_overlay_for_gpgme
47 {
48 public:
50
52 generic_file_overlay_for_gpgme(generic_file *f);
53
55 generic_file_overlay_for_gpgme(const generic_file_overlay_for_gpgme & ref) = delete;
56
58 generic_file_overlay_for_gpgme(generic_file_overlay_for_gpgme && re) noexcept = delete;
59
61 generic_file_overlay_for_gpgme & operator = (const generic_file_overlay_for_gpgme & ref) = delete;
62
64 generic_file_overlay_for_gpgme & operator = (generic_file_overlay_for_gpgme && ref) noexcept = delete;
65
66 #ifdef GPGME_SUPPORT
67 ~generic_file_overlay_for_gpgme() { gpgme_data_release(handle); };
69
71 gpgme_data_t get_gpgme_handle() const { return handle; };
72
73 generic_file *get_below() { return below; };
74
75 private:
76 generic_file *below;
77 gpgme_data_t handle;
78 gpgme_data_cbs cbs;
79
80 #endif
81 };
82
84
85 } // end of namespace
86
87 #endif
libdar::generic_file_overlay_for_gpgme::generic_file_overlay_for_gpgme
generic_file_overlay_for_gpgme(generic_file *f)
create a gpgme data buffer of the given generic_file
libdar::generic_file_overlay_for_gpgme::generic_file_overlay_for_gpgme
generic_file_overlay_for_gpgme(const generic_file_overlay_for_gpgme &ref)=delete
no copy constructor allowed
libdar::generic_file_overlay_for_gpgme::generic_file_overlay_for_gpgme
generic_file_overlay_for_gpgme(generic_file_overlay_for_gpgme &&re) noexcept=delete
no move constructor allowed
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:77
libdar::generic_file_overlay_for_gpgme
generic_file interface for for gpgme
Definition: generic_file_overlay_for_gpgme.hpp:47
libdar::generic_file_overlay_for_gpgme::operator=
generic_file_overlay_for_gpgme & operator=(const generic_file_overlay_for_gpgme &ref)=delete
no asignment operator
libdar
libdar namespace encapsulate all libdar symbols
Definition: archive.hpp:47