Switch to uploader thread for log file uploads.

This commit is contained in:
lotodore
2012-12-20 14:29:43 -08:00
parent fe7f34a504
commit 26507df7ef
17 changed files with 240 additions and 142 deletions
+7 -2
View File
@@ -35,7 +35,8 @@ public:
// Set the parameters. Does not do any error checking.
// Throws an exception on failure.
void Init(const std::string &url, const std::string &targetFileName,
const std::string &user = "", const std::string &password = "", size_t filesize = 0);
const std::string &user = "", const std::string &password = "",
size_t filesize = 0, const std::string &httpPost = "");
// Returns true when done, false should call again.
// Throws an exception on error.
@@ -44,11 +45,15 @@ public:
// Close all handles.
void Cleanup();
// Get and reset the last (error) message.
std::string ResetLastMessage();
protected:
boost::shared_ptr<TransferData> GetData();
virtual void InternalInit(const std::string &url, const std::string &targetFileName,
const std::string &user, const std::string &password, size_t filesize) = 0;
const std::string &user, const std::string &password,
size_t filesize, const std::string &httpPost) = 0;
private: