aboutsummaryrefslogtreecommitdiff
path: root/src/fingerclient.hpp
diff options
context:
space:
mode:
authorFelix (xq) Queißner <git@mq32.de>2020-06-16 22:01:59 +0200
committerFelix (xq) Queißner <git@mq32.de>2020-06-16 22:01:59 +0200
commita3f3e3933c4a2522e233917a6795c6e9d677e65c (patch)
tree6e1bd483bbd5e8ca6fee4566e544de48bfa754a6 /src/fingerclient.hpp
parentbc18d9356828f1ae40d3b4ce5432b30ca13cfc15 (diff)
downloadkristall-a3f3e3933c4a2522e233917a6795c6e9d677e65c.tar.gz
Refactoring: Changes internal structure of requests and unifies a lot of code. Now all errors are handled the same.
Diffstat (limited to 'src/fingerclient.hpp')
-rw-r--r--src/fingerclient.hpp19
1 files changed, 8 insertions, 11 deletions
diff --git a/src/fingerclient.hpp b/src/fingerclient.hpp
index 7fd2ae5..87ddc7e 100644
--- a/src/fingerclient.hpp
+++ b/src/fingerclient.hpp
@@ -5,26 +5,23 @@
#include <QTcpSocket>
#include <QUrl>
-class FingerClient : public QObject
+#include "protocolhandler.hpp"
+
+class FingerClient : public ProtocolHandler
{
Q_OBJECT
public:
- explicit FingerClient(QObject *parent = nullptr);
+ explicit FingerClient();
~FingerClient() override;
- bool startRequest(QUrl const & url);
-
- bool isInProgress() const;
-
- bool cancelRequest();
+ bool supportsScheme(QString const & scheme) const override;
-signals:
- void requestProgress(qint64 transferred);
+ bool startRequest(QUrl const & url) override;
- void requestComplete(QByteArray const & data, QString const & mime);
+ bool isInProgress() const override;
- void requestFailed(QString const & message);
+ bool cancelRequest() override;
private slots:
void on_connected();