Disk ARchive 2.7.7
Full featured and portable backup and archiving tool
entrepot_libcurl5.hpp
Go to the documentation of this file.
1/*********************************************************************/
2// dar - disk archive - a backup/restoration program
3// Copyright (C) 2002-2022 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 ENTREPOT_LIBCURL5_HPP
27#define ENTREPOT_LIBCURL5_HPP
28
29#include "../my_config.h"
30
31extern "C"
32{
33#if LIBCURL_AVAILABLE
34#if HAVE_CURL_CURL_H
35#include <curl/curl.h>
36#endif
37#endif
38}
39
40#include <string>
41#include <deque>
42#include "entrepot_libcurl.hpp"
43#include "user_interaction5.hpp"
44
45namespace libdar5
46{
47
50
52
54
56
57 class entrepot_libcurl : public libdar::entrepot_libcurl
58 {
59 public:
60 entrepot_libcurl(user_interaction & dialog,
61 mycurl_protocol proto,
62 const std::string & login,
63 const secu_string & password,
64 const std::string & host,
65 const std::string & port,
66 bool auth_from_file,
67 const std::string & sftp_pub_keyfile,
68 const std::string & sftp_prv_keyfile,
69 const std::string & sftp_known_hosts,
70 U_I waiting_time):
72 proto,
73 login,
74 password,
75 host,
76 port,
77 auth_from_file,
78 sftp_pub_keyfile,
79 sftp_prv_keyfile,
80 sftp_known_hosts,
81 waiting_time)
82 {}
83
84 entrepot_libcurl(const entrepot_libcurl & ref) = default;
85 entrepot_libcurl(entrepot_libcurl && ref) noexcept = default;
86 entrepot_libcurl & operator = (const entrepot_libcurl & ref) = default;
87 entrepot_libcurl & operator = (entrepot_libcurl && ref) noexcept = default;
88 ~entrepot_libcurl() throw () {};
89
90 };
91
93
94} // end of namespace
95
96#endif
for managing archive into a remote repository
entrepot_libcurl(const std::shared_ptr< user_interaction > &dialog, mycurl_protocol proto, const std::string &login, const secu_string &password, const std::string &host, const std::string &port, bool auth_from_file, const std::string &sftp_pub_keyfile, const std::string &sftp_prv_keyfile, const std::string &sftp_known_hosts, U_I waiting_time)
defines the implementation for remote filesystem entrepot using libcurl
std::shared_ptr< user_interaction > user_interaction5_clone_to_shared_ptr(user_interaction &dialog)
convert a user_interaction to a shared_pointer on a clone of that user_interaction
mycurl_protocol
libcurl protocols supported by libdar
libdar5 namespace encapsulate all libdar symbols
Definition: archive5.hpp:37
libdar namespace encapsulate all libdar symbols
Definition: archive.hpp:47
API v5 backward compatible class user_interaction.