QXmpp
Version:0.9.3
|
00001 /* 00002 * Copyright (C) 2008-2014 The QXmpp developers 00003 * 00004 * Author: 00005 * Manjeet Dahiya 00006 * 00007 * Source: 00008 * https://github.com/qxmpp-project/qxmpp 00009 * 00010 * This file is a part of QXmpp library. 00011 * 00012 * This library is free software; you can redistribute it and/or 00013 * modify it under the terms of the GNU Lesser General Public 00014 * License as published by the Free Software Foundation; either 00015 * version 2.1 of the License, or (at your option) any later version. 00016 * 00017 * This library is distributed in the hope that it will be useful, 00018 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00019 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00020 * Lesser General Public License for more details. 00021 * 00022 */ 00023 00024 #ifndef QXMPPDISCOVERYMANAGER_H 00025 #define QXMPPDISCOVERYMANAGER_H 00026 00027 #include "QXmppClientExtension.h" 00028 00029 class QXmppDataForm; 00030 class QXmppDiscoveryIq; 00031 class QXmppDiscoveryManagerPrivate; 00032 00037 00038 class QXMPP_EXPORT QXmppDiscoveryManager : public QXmppClientExtension 00039 { 00040 Q_OBJECT 00041 00042 public: 00043 QXmppDiscoveryManager(); 00044 ~QXmppDiscoveryManager(); 00045 00046 QXmppDiscoveryIq capabilities(); 00047 00048 QString requestInfo(const QString& jid, const QString& node = QString()); 00049 QString requestItems(const QString& jid, const QString& node = QString()); 00050 00051 QString clientCapabilitiesNode() const; 00052 void setClientCapabilitiesNode(const QString&); 00053 00054 // http://xmpp.org/registrar/disco-categories.html#client 00055 QString clientCategory() const; 00056 void setClientCategory(const QString&); 00057 00058 void setClientName(const QString&); 00059 QString clientName() const; 00060 00061 QString clientType() const; 00062 void setClientType(const QString&); 00063 00064 QXmppDataForm clientInfoForm() const; 00065 void setClientInfoForm(const QXmppDataForm &form); 00066 00068 QStringList discoveryFeatures() const; 00069 bool handleStanza(const QDomElement &element); 00071 00072 signals: 00074 void infoReceived(const QXmppDiscoveryIq&); 00075 00077 void itemsReceived(const QXmppDiscoveryIq&); 00078 00079 private: 00080 QXmppDiscoveryManagerPrivate *d; 00081 }; 00082 00083 #endif // QXMPPDISCOVERYMANAGER_H