summaryrefslogtreecommitdiff
path: root/client/DownloadClient.h
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss@sss.chaoslab.ru>2012-09-04 12:29:59 +0300
committerGluzskiy Alexandr <sss@sss.chaoslab.ru>2012-09-04 12:29:59 +0300
commit6d8b331a37a025f4a16d8278da715e7a628b33d3 (patch)
tree11b7880b2afe9575f99a0a9eeb2ba97b8e6c88b9 /client/DownloadClient.h
parent1052c8bd510b92827a61aba725083c9feb24e042 (diff)
parentad1559db52cf01869c0fb31252ad9f69af2ddd4c (diff)
Merge branch 'master' of ssh://sss.chaoslab.ru//home/git/proxy_ui
Diffstat (limited to 'client/DownloadClient.h')
-rw-r--r--client/DownloadClient.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/client/DownloadClient.h b/client/DownloadClient.h
index 229074f..8488d47 100644
--- a/client/DownloadClient.h
+++ b/client/DownloadClient.h
@@ -23,6 +23,7 @@
#include <QObject>
#include "SslClient.h"
+using std::map;
using std::pair;
using std::string;
using std::vector;
@@ -70,7 +71,15 @@ signals:
*/
void downloadFinished();
+private slots:
+ void FileDataRecieved(SslClient::RequestType &type, QByteArray &confdata);
+
private:
+ /**
+ * @brief maximum number of retries when downloading files
+ */
+ static const int MAX_DOWNLOAD_ATTEMPTS = 3;
+
/**
* @brief indicates that program is downloading file(s) right now
*/
@@ -86,6 +95,11 @@ private:
*/
int currentId;
+ /**
+ * @brief number of failed download attempt per single file
+ */
+ map<string, int> status;
+
/**
* @brief List of file to
*/
@@ -95,9 +109,6 @@ private:
* @brief start file-by-file downloading process
*/
void DoDownload();
-
-private slots:
- void FileDataRecieved(SslClient::RequestType &type, QByteArray &confdata);
};
#endif