QXmpp  Version: 1.8.1
QXmppClient_p.h
1 // SPDX-FileCopyrightText: 2020 Manjeet Dahiya <manjeetdahiya@gmail.com>
2 // SPDX-FileCopyrightText: 2020 Linus Jahn <lnj@kaidan.im>
3 //
4 // SPDX-License-Identifier: LGPL-2.1-or-later
5 
6 //
7 // W A R N I N G
8 // -------------
9 //
10 // This file is not part of the QXmpp API.
11 //
12 // This header file may change from version to version without notice,
13 // or even be removed.
14 //
15 // We mean it.
16 //
17 
18 #ifndef QXMPPCLIENT_P_H
19 #define QXMPPCLIENT_P_H
20 
21 #include "QXmppOutgoingClient.h"
22 #include "QXmppPresence.h"
23 
24 #include <chrono>
25 
26 class QXmppClient;
28 class QXmppE2eeExtension;
29 class QXmppLogger;
30 class QTimer;
31 
32 class QXmppClientPrivate
33 {
34 public:
35  QXmppClientPrivate(QXmppClient *qq);
36 
38  QXmppPresence clientPresence;
39  QList<QXmppClientExtension *> extensions;
40  QXmppLogger *logger;
42  QXmppOutgoingClient *stream;
43 
44  QXmppE2eeExtension *encryptionExtension;
45 
46  // reconnection
47  bool receivedConflict;
48  int reconnectionTries;
49  QTimer *reconnectionTimer;
50 
51  void addProperCapability(QXmppPresence &presence);
52  std::chrono::milliseconds getNextReconnectTime() const;
53 
54  static QStringList discoveryFeatures();
55  void onErrorOccurred(const QString &text, const QXmppOutgoingClient::ConnectionError &err, QXmppClient::Error oldError);
56 
57 private:
58  QXmppClient *q;
59 };
60 
61 #endif // QXMPPCLIENT_P_H
Definition: QXmppE2eeExtension.h:22
Error
Definition: QXmppClient.h:74
The QXmppLogger class represents a sink for logging messages.
Definition: QXmppLogger.h:28
The QXmppPresence class represents an XMPP presence stanza.
Definition: QXmppPresence.h:20
The QXmppClientExtension class is the base class for QXmppClient extensions.
Definition: QXmppClientExtension.h:31
Main class for starting and managing connections to XMPP servers.
Definition: QXmppClient.h:59