libQuotient
A Qt library for building matrix clients
networkaccessmanager.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: 2018 Kitsune Ral <kitsune-ral@users.sf.net>
2 // SPDX-License-Identifier: LGPL-2.1-or-later
3 
4 #pragma once
5 
6 #include "Quotient/quotient_export.h"
7 
8 #include <QtNetwork/QNetworkAccessManager>
9 
10 namespace Quotient {
11 
13  Q_OBJECT
14 public:
16 
17  static void addAccount(const QString& accountId, const QUrl& homeserver,
18  const QByteArray& accessToken = {});
21 
23  static void addIgnoredSslError(const QSslError& error);
24  static void clearIgnoredSslErrors();
25 
26  static void setAccessToken(const QString& userId, const QByteArray& token);
27 
28  //! Get a NAM instance for the current thread
30 
31 private Q_SLOTS:
32  QStringList supportedSchemesImplementation() const; // clazy:exclude=const-signal-or-slot
33 
34 private:
36  QIODevice* outgoingData = nullptr) override;
37 };
38 } // namespace Quotient