aboutsummaryrefslogtreecommitdiff
path: root/launcher/net/MetaCacheSink.h
diff options
context:
space:
mode:
Diffstat (limited to 'launcher/net/MetaCacheSink.h')
-rw-r--r--launcher/net/MetaCacheSink.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/launcher/net/MetaCacheSink.h b/launcher/net/MetaCacheSink.h
new file mode 100644
index 00000000..edcf7ad1
--- /dev/null
+++ b/launcher/net/MetaCacheSink.h
@@ -0,0 +1,22 @@
+#pragma once
+#include "FileSink.h"
+#include "ChecksumValidator.h"
+#include "net/HttpMetaCache.h"
+
+namespace Net {
+class MetaCacheSink : public FileSink
+{
+public: /* con/des */
+ MetaCacheSink(MetaEntryPtr entry, ChecksumValidator * md5sum);
+ virtual ~MetaCacheSink();
+ bool hasLocalData() override;
+
+protected: /* methods */
+ JobStatus initCache(QNetworkRequest & request) override;
+ JobStatus finalizeCache(QNetworkReply & reply) override;
+
+private: /* data */
+ MetaEntryPtr m_entry;
+ ChecksumValidator * m_md5Node;
+};
+}