QXmpp  Version: 1.6.0
QXmppTrustMessageKeyOwner.h
1 // SPDX-FileCopyrightText: 2021 Melvin Keskin <melvo@olomono.de>
2 //
3 // SPDX-License-Identifier: LGPL-2.1-or-later
4 
5 #ifndef QXMPPTRUSTMESSAGEKEYOWNER_H
6 #define QXMPPTRUSTMESSAGEKEYOWNER_H
7 
8 #include "QXmppGlobal.h"
9 
10 #include <QSharedDataPointer>
11 
12 class QDomElement;
13 class QXmlStreamWriter;
14 class QXmppTrustMessageKeyOwnerPrivate;
15 
16 class QXMPP_EXPORT QXmppTrustMessageKeyOwner
17 {
18 public:
23 
26 
27  QString jid() const;
28  void setJid(const QString &jid);
29 
30  QList<QByteArray> trustedKeys() const;
31  void setTrustedKeys(const QList<QByteArray> &keyIds);
32 
33  QList<QByteArray> distrustedKeys() const;
34  void setDistrustedKeys(const QList<QByteArray> &keyIds);
35 
37  void parse(const QDomElement &element);
38  void toXml(QXmlStreamWriter *writer) const;
40 
41  static bool isTrustMessageKeyOwner(const QDomElement &element);
42 
43 private:
44  QSharedDataPointer<QXmppTrustMessageKeyOwnerPrivate> d;
45 };
46 
47 Q_DECLARE_TYPEINFO(QXmppTrustMessageKeyOwner, Q_MOVABLE_TYPE);
48 
49 #endif // QXMPPTRUSTMESSAGEKEYOWNER_H
The QXmppTrustMessageKeyOwner class represents a key owner of the trust message as defined by XEP-043...
Definition: QXmppTrustMessageKeyOwner.h:16