From af22e07a2300dc18ec62eee30508569062d918b3 Mon Sep 17 00:00:00 2001 From: Linus Jahn Date: Wed, 9 Sep 2020 15:32:01 +0200 Subject: QXmppClient: Advertise stream management state --- src/client/QXmppClient.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'src/client/QXmppClient.h') diff --git a/src/client/QXmppClient.h b/src/client/QXmppClient.h index 02c580c3..0afe6235 100644 --- a/src/client/QXmppClient.h +++ b/src/client/QXmppClient.h @@ -89,7 +89,7 @@ class QXmppVersionManager; /// - QXmppEntityTimeManager /// /// \ingroup Core - +/// class QXMPP_EXPORT QXmppClient : public QXmppLoggable { Q_OBJECT @@ -118,6 +118,16 @@ public: }; Q_ENUM(State) + /// Describes the use of \xep{0198}: Stream Management + enum StreamManagementState { + /// Stream Management is not used. + NoStreamManagement, + /// Stream Management is used and the previous stream has not been resumed. + NewStream, + /// Stream Management is used and the previous stream has been resumed. + ResumedStream + }; + QXmppClient(QObject *parent = nullptr); ~QXmppClient() override; @@ -127,6 +137,7 @@ public: QList extensions(); + /// /// \brief Returns the extension which can be cast into type T*, or 0 /// if there is no such extension. /// @@ -151,6 +162,7 @@ public: return nullptr; } + /// /// \brief Returns the index of an extension /// /// Usage example: @@ -182,6 +194,8 @@ public: bool isActive() const; void setActive(bool active); + StreamManagementState streamManagementState() const; + QXmppPresence clientPresence() const; void setClientPresence(const QXmppPresence &presence); -- cgit v1.2.3