11
11
#include < thread>
12
12
#include < memory>
13
13
#include < functional>
14
- #include < boost/ asio/io_service.hpp>
15
- #include < boost/ asio/strand.hpp>
14
+ #include < asio/io_service.hpp>
15
+ #include < asio/strand.hpp>
16
16
#include < boost/network/protocol/http/traits/connection_policy.hpp>
17
17
18
18
namespace boost {
@@ -32,13 +32,13 @@ struct async_client
32
32
typedef typename string<Tag>::type string_type;
33
33
34
34
typedef std::function<void (boost::iterator_range<char const *> const &,
35
- system ::error_code const &)> body_callback_function_type;
35
+ std ::error_code const &)> body_callback_function_type;
36
36
37
37
typedef std::function<bool (string_type&)> body_generator_function_type;
38
38
39
39
async_client (bool cache_resolved, bool follow_redirect,
40
40
bool always_verify_peer, int timeout,
41
- std::shared_ptr<boost:: asio::io_service> service,
41
+ std::shared_ptr<asio::io_service> service,
42
42
optional<string_type> certificate_filename,
43
43
optional<string_type> verify_path,
44
44
optional<string_type> certificate_file,
@@ -47,10 +47,10 @@ struct async_client
47
47
: connection_base(cache_resolved, follow_redirect, timeout),
48
48
service_ptr (service.get()
49
49
? service
50
- : std::make_shared<boost:: asio::io_service>()),
50
+ : std::make_shared<asio::io_service>()),
51
51
service_(*service_ptr),
52
52
resolver_(service_),
53
- sentinel_(new boost:: asio::io_service::work(service_)),
53
+ sentinel_(new asio::io_service::work(service_)),
54
54
certificate_filename_(std::move(certificate_filename)),
55
55
verify_path_(std::move(verify_path)),
56
56
certificate_file_(std::move(certificate_file)),
@@ -59,7 +59,7 @@ struct async_client
59
59
ssl_options_(ssl_options),
60
60
always_verify_peer_(always_verify_peer) {
61
61
connection_base::resolver_strand_.reset (
62
- new boost:: asio::io_service::strand (service_));
62
+ new asio::io_service::strand (service_));
63
63
if (!service)
64
64
lifetime_thread_.reset (new std::thread ([this ] () { service_.run (); }));
65
65
}
@@ -87,10 +87,10 @@ struct async_client
87
87
generator);
88
88
}
89
89
90
- std::shared_ptr<boost:: asio::io_service> service_ptr;
91
- boost:: asio::io_service& service_;
90
+ std::shared_ptr<asio::io_service> service_ptr;
91
+ asio::io_service& service_;
92
92
resolver_type resolver_;
93
- std::shared_ptr<boost:: asio::io_service::work> sentinel_;
93
+ std::shared_ptr<asio::io_service::work> sentinel_;
94
94
std::shared_ptr<std::thread> lifetime_thread_;
95
95
optional<string_type> certificate_filename_;
96
96
optional<string_type> verify_path_;
0 commit comments