diff --git a/backends/twitter/Requests/RetweetRequest.h b/backends/twitter/Requests/RetweetRequest.h new file mode 100644 index 0000000000000000000000000000000000000000..04a48ffcdc9d91b92ab0160fae67932ac9701b91 --- /dev/null +++ b/backends/twitter/Requests/RetweetRequest.h @@ -0,0 +1,40 @@ +#ifndef RETWEET_H +#define RETWEET_H + +#include "../ThreadPool.h" +#include "../TwitterResponseParser.h" +#include "../libtwitcurl/twitcurl.h" +#include "transport/networkplugin.h" +#include "transport/logging.h" +#include +#include +#include + +using namespace Transport; +class RetweetRequest : public Thread +{ + twitCurl *twitObj; + std::string data; + std::string user; + std::string replyMsg; + bool success; + boost::function < void (std::string&, std::string &) > callBack; + + public: + RetweetRequest(twitCurl *obj, const std::string &_user, const std::string &_data, + boost::function < void (std::string &, std::string &) > _cb) { + twitObj = obj->clone(); + data = _data; + user = _user; + callBack = _cb; + } + + ~RetweetRequest() { + delete twitObj; + } + + void run(); + void finalize(); +}; + +#endif