2010-06-25 07:05:29 -07:00
|
|
|
#ifndef ZIPNETWORKREPLY_H
|
|
|
|
|
#define ZIPNETWORKREPLY_H
|
|
|
|
|
|
2011-02-12 23:55:51 +01:00
|
|
|
#include <QtNetwork/QNetworkReply>
|
2010-06-25 07:05:29 -07:00
|
|
|
|
|
|
|
|
class OdfContainer;
|
|
|
|
|
|
|
|
|
|
class ZipNetworkReply : public QNetworkReply
|
|
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
public:
|
2010-06-25 10:08:51 -07:00
|
|
|
ZipNetworkReply(QObject* parent, OdfContainer *odf, const QNetworkRequest &req, const QNetworkAccessManager::Operation op);
|
2010-06-25 07:05:29 -07:00
|
|
|
|
2010-06-25 10:08:51 -07:00
|
|
|
void close();
|
2010-06-25 07:05:29 -07:00
|
|
|
void abort();
|
2010-06-25 10:08:51 -07:00
|
|
|
qint64 bytesAvailable() const;
|
|
|
|
|
qint64 size() const;
|
|
|
|
|
|
2010-06-25 07:05:29 -07:00
|
|
|
protected:
|
|
|
|
|
qint64 readData(char *data, qint64 maxSize) ;
|
2010-06-25 10:08:51 -07:00
|
|
|
|
2010-06-25 07:05:29 -07:00
|
|
|
private:
|
2010-06-25 10:08:51 -07:00
|
|
|
QIODevice *m_file;
|
|
|
|
|
qint64 m_remaining;
|
2010-06-25 07:05:29 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif // ODF_H
|