25 #define _HandlePool_h 1
32 #include <curl/curl.h>
43 pthread_mutex_t& m_mutex;
49 Lock(pthread_mutex_t &lock);
65 char d_errbuf[CURL_ERROR_SIZE];
67 struct curl_slist *d_headers;
116 unsigned int d_max_easy_handles;
118 std::vector<dmrpp_easy_handle *> d_easy_handles;
122 pthread_mutex_t d_get_easy_handle_mutex;
132 for (std::vector<dmrpp_easy_handle *>::iterator i = d_easy_handles.begin(), e = d_easy_handles.end();
137 for (
auto &d_easy_handle: d_easy_handles) {
138 delete d_easy_handle;
141 delete d_multi_handle;
144 unsigned int get_max_handles()
const
146 return d_max_easy_handles;
151 return d_multi_handle;
void release_handle(dmrpp_easy_handle *h)
dmrpp_easy_handle * get_easy_handle(Chunk *chunk)
Bundle a libcurl easy handle to other information.
void read_data()
This is the read_data() method for serial transfers.
dmrpp_easy_handle()
Build a string with hex info about stuff libcurl gets.
Encapsulate a libcurl multi handle.
void add_easy_handle(dmrpp_easy_handle *eh)
Add an Easy Handle to a Multi Handle object.
void read_data()
The read_data() method for parallel transfers.