diff options
author | Egor Pugin <egor.pugin@gmail.com> | 2018-07-04 19:11:03 +0300 |
---|---|---|
committer | Egor Pugin <egor.pugin@gmail.com> | 2018-07-04 19:11:03 +0300 |
commit | 95f86f4ce18e65d45894d5a130c4bdaf8ecbaac5 (patch) | |
tree | 0235eaef9d2dcd9725c1eb9d24c8de0201ba6fcc /include/tgbot/Api.h | |
parent | 7f388398bbcff916f5507770af727ef9ad59f33d (diff) |
Implement CurlHttpClient.
Diffstat (limited to 'include/tgbot/Api.h')
-rw-r--r-- | include/tgbot/Api.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/tgbot/Api.h b/include/tgbot/Api.h index 8dea56a..e73fbe1 100644 --- a/include/tgbot/Api.h +++ b/include/tgbot/Api.h @@ -28,6 +28,7 @@ #include <boost/property_tree/ptree.hpp> +#include "tgbot/net/HttpClient.h" #include "tgbot/net/HttpReqArg.h" #include "tgbot/types/User.h" #include "tgbot/types/Message.h" @@ -62,7 +63,7 @@ typedef std::shared_ptr<std::vector<std::string>> StringArrayPtr; friend class Bot; public: - Api(const std::string& token); + Api(const std::string& token, const HttpClient &httpClientDriver); /** * @brief A simple method for testing your bot's auth token. @@ -890,6 +891,7 @@ private: boost::property_tree::ptree sendRequest(const std::string& method, const std::vector<HttpReqArg>& args = std::vector<HttpReqArg>()) const; const std::string _token; + const HttpClient &_httpClientDriver; }; } |