3#include <Kanoop/kanoopprotocol.h>
4#include <Kanoop/http/httpoperation.h>
51 virtual void postGetHook(QNetworkReply* reply) { Q_UNUSED(reply) }
58 QList<KeyValuePair> _parameters;
59 bool _streamingRead =
false;
62 void onStreamingReadyRead();
HTTP GET operation executed asynchronously on a dedicated thread.
bool streamingRead() const
streamingRead Set to true to return the response piece by piece as available using the dataAvailable(...
void dataAvailable(const QByteArray &data)
Emitted when a chunk of data is available during a streaming read.
virtual void preGetHook(QNetworkRequest *)
Hook called before the GET request is sent.
void setStreamingRead(bool value)
Enable or disable streaming read mode.
virtual void postGetHook(QNetworkReply *reply)
Hook called after the GET reply is received.
virtual void postReplyHook(QNetworkReply *reply) override
Hook called after the network reply is processed.
virtual void execute() override
Execute the HTTP GET request.
void downloadProgress(qint64 bytesReceived, qint64 bytesTotal)
Emitted to report download progress.
HttpGet(const QString &url)
Construct an HTTP GET operation for the given URL.
void addParameter(const QString &key, const QString &value)
Add a query parameter to the GET request.
Base class for HTTP operations executed asynchronously on a dedicated thread.