First version of server side avatar upload feature (support for external avatar server). Still hard coded, cannot be configured.

This commit is contained in:
lotodore
2009-02-21 23:33:30 +00:00
parent f78de09078
commit e7c70ad9ad
14 changed files with 560 additions and 153 deletions
+5 -19
View File
@@ -21,32 +21,18 @@
#ifndef _DOWNLOADHELPER_H_
#define _DOWNLOADHELPER_H_
#include <string>
#include <memory>
struct DownloadData;
#include <net/transferhelper.h>
class DownloadHelper
class DownloadHelper : public TransferHelper
{
public:
DownloadHelper();
virtual ~DownloadHelper();
// Set the parameters. Does not do any error checking.
// Throws an exception on failure.
void Init(const std::string &url, const std::string &targetFileName);
// Returns true when done, false should call again.
// Throws an exception on error.
bool Process();
// Close all handles.
void Cleanup();
private:
std::auto_ptr<DownloadData> m_data;
protected:
virtual void InternalInit(const std::string &url, const std::string &targetFileName,
const std::string &user, const std::string &password);
};
#endif