diff options
| author | Linus Jahn <lnj@kaidan.im> | 2020-02-04 16:11:24 +0100 |
|---|---|---|
| committer | Linus Jahn <lnj@kaidan.im> | 2020-02-04 16:13:03 +0100 |
| commit | a4d292ecb0a3459825e81a2b6d81df7a6d6635fb (patch) | |
| tree | 0808b3b527d030c2f2cbd846f832d639d6a20c31 /src | |
| parent | 99c0df8616056318eb94539cfde497d3b10f3ae0 (diff) | |
| download | qxmpp-a4d292ecb0a3459825e81a2b6d81df7a6d6635fb.tar.gz | |
Fix undocumented Q_PROPERTies
Diffstat (limited to 'src')
| -rw-r--r-- | src/base/QXmppLogger.cpp | 10 | ||||
| -rw-r--r-- | src/base/QXmppLogger.h | 17 | ||||
| -rw-r--r-- | src/base/QXmppStun.cpp | 3 | ||||
| -rw-r--r-- | src/base/QXmppStun.h | 4 | ||||
| -rw-r--r-- | src/client/QXmppCallManager.cpp | 14 | ||||
| -rw-r--r-- | src/client/QXmppCallManager.h | 17 | ||||
| -rw-r--r-- | src/client/QXmppClient.cpp | 4 | ||||
| -rw-r--r-- | src/client/QXmppClient.h | 8 | ||||
| -rw-r--r-- | src/client/QXmppMucManager.cpp | 22 | ||||
| -rw-r--r-- | src/client/QXmppMucManager.h | 40 | ||||
| -rw-r--r-- | src/client/QXmppTransferManager.cpp | 30 | ||||
| -rw-r--r-- | src/client/QXmppTransferManager.h | 32 | ||||
| -rw-r--r-- | src/server/QXmppServer.cpp | 3 | ||||
| -rw-r--r-- | src/server/QXmppServer.h | 3 |
14 files changed, 117 insertions, 90 deletions
diff --git a/src/base/QXmppLogger.cpp b/src/base/QXmppLogger.cpp index 8162d118..54c096dc 100644 --- a/src/base/QXmppLogger.cpp +++ b/src/base/QXmppLogger.cpp @@ -145,9 +145,6 @@ QXmppLogger *QXmppLogger::getLogger() return m_logger; } -/// Returns the handler for logging messages. -/// - QXmppLogger::LoggingType QXmppLogger::loggingType() { return d->loggingType; @@ -165,9 +162,6 @@ void QXmppLogger::setLoggingType(QXmppLogger::LoggingType type) } } -/// Returns the types of messages to log. -/// - QXmppLogger::MessageTypes QXmppLogger::messageTypes() { return d->messageTypes; @@ -232,10 +226,6 @@ void QXmppLogger::updateCounter(const QString &counter, qint64 amount) Q_UNUSED(amount); } -/// Returns the path to which logging messages should be written. -/// -/// \sa loggingType() - QString QXmppLogger::logFilePath() { return d->logFilePath; diff --git a/src/base/QXmppLogger.h b/src/base/QXmppLogger.h index 4513b59a..a1b62b5b 100644 --- a/src/base/QXmppLogger.h +++ b/src/base/QXmppLogger.h @@ -37,16 +37,21 @@ class QXmppLoggerPrivate; +/// /// \brief The QXmppLogger class represents a sink for logging messages. /// /// \ingroup Core - +/// class QXMPP_EXPORT QXmppLogger : public QObject { Q_OBJECT Q_FLAGS(MessageType MessageTypes) + + /// The path to which logging messages should be written Q_PROPERTY(QString logFilePath READ logFilePath WRITE setLogFilePath) + /// The handler for logging messages Q_PROPERTY(LoggingType loggingType READ loggingType WRITE setLoggingType) + /// The types of messages to log Q_PROPERTY(MessageTypes messageTypes READ messageTypes WRITE setMessageTypes) public: @@ -76,12 +81,22 @@ public: static QXmppLogger *getLogger(); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the handler for logging messages. QXmppLogger::LoggingType loggingType(); void setLoggingType(QXmppLogger::LoggingType type); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// + /// Returns the path to which logging messages should be written. + /// + /// \sa loggingType() + /// QString logFilePath(); void setLogFilePath(const QString &path); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the types of messages to log. QXmppLogger::MessageTypes messageTypes(); void setMessageTypes(QXmppLogger::MessageTypes types); diff --git a/src/base/QXmppStun.cpp b/src/base/QXmppStun.cpp index 703ca962..636afc38 100644 --- a/src/base/QXmppStun.cpp +++ b/src/base/QXmppStun.cpp @@ -2568,9 +2568,6 @@ bool QXmppIceConnection::isConnected() const return true; } -/// Returns the ICE gathering state, that is the discovery of -/// local candidates. - QXmppIceConnection::GatheringState QXmppIceConnection::gatheringState() const { return d->gatheringState; diff --git a/src/base/QXmppStun.h b/src/base/QXmppStun.h index 6b66aad4..c801e4af 100644 --- a/src/base/QXmppStun.h +++ b/src/base/QXmppStun.h @@ -241,6 +241,7 @@ private: class QXMPP_EXPORT QXmppIceConnection : public QXmppLoggable { Q_OBJECT + /// The ICE gathering state, that is the discovery of local candidates Q_PROPERTY(QXmppIceConnection::GatheringState gatheringState READ gatheringState NOTIFY gatheringStateChanged) public: @@ -274,6 +275,9 @@ public: bool bind(const QList<QHostAddress> &addresses); bool isConnected() const; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the ICE gathering state, that is the discovery of local + /// candidates. GatheringState gatheringState() const; signals: diff --git a/src/client/QXmppCallManager.cpp b/src/client/QXmppCallManager.cpp index 5d63b4a6..6ce6687a 100644 --- a/src/client/QXmppCallManager.cpp +++ b/src/client/QXmppCallManager.cpp @@ -506,8 +506,6 @@ QXmppRtpAudioChannel *QXmppCall::audioChannel() const return nullptr; } -/// Returns the audio mode. - QIODevice::OpenMode QXmppCall::audioMode() const { return d->audioMode; @@ -525,8 +523,6 @@ QXmppRtpVideoChannel *QXmppCall::videoChannel() const return nullptr; } -/// Returns the video mode. - QIODevice::OpenMode QXmppCall::videoMode() const { return d->videoMode; @@ -544,9 +540,6 @@ void QXmppCall::terminated() d->setState(QXmppCall::FinishedState); } -/// Returns the call's direction. -/// - QXmppCall::Direction QXmppCall::direction() const { return d->direction; @@ -586,9 +579,6 @@ void QXmppCall::localCandidatesChanged() d->sendRequest(iq); } -/// Returns the remote party's JID. -/// - QString QXmppCall::jid() const { return d->jid; @@ -631,10 +621,6 @@ QString QXmppCall::sid() const return d->sid; } -/// Returns the call's state. -/// -/// \sa stateChanged() - QXmppCall::State QXmppCall::state() const { return d->state; diff --git a/src/client/QXmppCallManager.h b/src/client/QXmppCallManager.h index 78cafe5b..98579601 100644 --- a/src/client/QXmppCallManager.h +++ b/src/client/QXmppCallManager.h @@ -79,14 +79,27 @@ public: ~QXmppCall() override; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the call's direction. QXmppCall::Direction direction() const; + /// Returns the remote party's JID. QString jid() const; - QString sid() const; + /// + /// Returns the call's state. + /// + /// \sa stateChanged() + /// QXmppCall::State state() const; + QString sid() const; + QXmppRtpAudioChannel *audioChannel() const; - QIODevice::OpenMode audioMode() const; QXmppRtpVideoChannel *videoChannel() const; + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the audio mode. + QIODevice::OpenMode audioMode() const; + /// Returns the video mode. QIODevice::OpenMode videoMode() const; signals: diff --git a/src/client/QXmppClient.cpp b/src/client/QXmppClient.cpp index 97785f25..c72ef078 100644 --- a/src/client/QXmppClient.cpp +++ b/src/client/QXmppClient.cpp @@ -351,8 +351,6 @@ void QXmppClient::sendMessage(const QString& bareJid, const QString& message) } } -/// Returns the client's current state. - QXmppClient::State QXmppClient::state() const { if (d->stream->isConnected()) @@ -523,8 +521,6 @@ void QXmppClient::_q_streamError(QXmppClient::Error err) emit error(err); } -/// Returns the QXmppLogger associated with the current QXmppClient. - QXmppLogger* QXmppClient::logger() const { return d->logger; diff --git a/src/client/QXmppClient.h b/src/client/QXmppClient.h index c4f07080..4225ad09 100644 --- a/src/client/QXmppClient.h +++ b/src/client/QXmppClient.h @@ -94,7 +94,10 @@ class QXmppVersionManager; class QXMPP_EXPORT QXmppClient : public QXmppLoggable { Q_OBJECT + + /// The QXmppLogger associated with the current QXmppClient Q_PROPERTY(QXmppLogger *logger READ logger WRITE setLogger NOTIFY loggerChanged) + /// The client's current state Q_PROPERTY(State state READ state NOTIFY stateChanged) public: @@ -184,12 +187,17 @@ public: void setClientPresence(const QXmppPresence &presence); QXmppConfiguration &configuration(); + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the QXmppLogger associated with the current QXmppClient. QXmppLogger *logger() const; void setLogger(QXmppLogger *logger); QAbstractSocket::SocketError socketError(); QString socketErrorString() const; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the client's current state. State state() const; QXmppStanza::Error::Condition xmppStreamError(); diff --git a/src/client/QXmppMucManager.cpp b/src/client/QXmppMucManager.cpp index d8645b59..32818e50 100644 --- a/src/client/QXmppMucManager.cpp +++ b/src/client/QXmppMucManager.cpp @@ -89,8 +89,6 @@ QXmppMucRoom *QXmppMucManager::addRoom(const QString &roomJid) return room; } -/// Returns the list of managed rooms. - QList<QXmppMucRoom *> QXmppMucManager::rooms() const { return d->rooms.values(); @@ -210,8 +208,6 @@ QXmppMucRoom::~QXmppMucRoom() delete d; } -/// Returns the actions you are allowed to perform on the room. - QXmppMucRoom::Actions QXmppMucRoom::allowedActions() const { return d->allowedActions; @@ -243,15 +239,11 @@ bool QXmppMucRoom::ban(const QString &jid, const QString &reason) return d->client->sendPacket(iq); } -/// Returns true if you are currently in the room. - bool QXmppMucRoom::isJoined() const { return d->participants.contains(d->ownJid()); } -/// Returns the chat room's bare JID. - QString QXmppMucRoom::jid() const { return d->jid; @@ -311,17 +303,11 @@ bool QXmppMucRoom::leave(const QString &message) return d->client->sendPacket(packet); } -/// Returns the chat room's human-readable name. -/// -/// This name will only be available after the room has been joined. - QString QXmppMucRoom::name() const { return d->name; } -/// Returns your own nickname. - QString QXmppMucRoom::nickName() const { return d->nickName; @@ -407,17 +393,11 @@ QXmppPresence QXmppMucRoom::participantPresence(const QString &jid) const return presence; } -/// Returns the list of participant JIDs. -/// -/// These JIDs are Occupant JIDs of the form "room@service/nick". - QStringList QXmppMucRoom::participants() const { return d->participants.keys(); } -/// Returns the chat room password. - QString QXmppMucRoom::password() const { return d->password; @@ -432,8 +412,6 @@ void QXmppMucRoom::setPassword(const QString &password) d->password = password; } -/// Returns the room's subject. - QString QXmppMucRoom::subject() const { return d->subject; diff --git a/src/client/QXmppMucManager.h b/src/client/QXmppMucManager.h index 85dd40b4..f1656b45 100644 --- a/src/client/QXmppMucManager.h +++ b/src/client/QXmppMucManager.h @@ -66,6 +66,9 @@ public: ~QXmppMucManager() override; QXmppMucRoom *addRoom(const QString &roomJid); + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the list of managed rooms. QList<QXmppMucRoom *> rooms() const; /// \cond @@ -102,13 +105,22 @@ class QXMPP_EXPORT QXmppMucRoom : public QObject { Q_OBJECT Q_FLAGS(Action Actions) + + /// The actions you are allowed to perform on the room Q_PROPERTY(QXmppMucRoom::Actions allowedActions READ allowedActions NOTIFY allowedActionsChanged) + /// Whether you are currently in the room Q_PROPERTY(bool isJoined READ isJoined NOTIFY isJoinedChanged) + /// The chat room's bare JID Q_PROPERTY(QString jid READ jid CONSTANT) + /// The chat room's human-readable name Q_PROPERTY(QString name READ name NOTIFY nameChanged) + /// Your own nickname Q_PROPERTY(QString nickName READ nickName WRITE setNickName NOTIFY nickNameChanged) + /// The list of participant JIDs Q_PROPERTY(QStringList participants READ participants NOTIFY participantsChanged) + /// The chat room password Q_PROPERTY(QString password READ password WRITE setPassword) + /// The room's subject Q_PROPERTY(QString subject READ subject WRITE setSubject NOTIFY subjectChanged) public: @@ -124,21 +136,49 @@ public: ~QXmppMucRoom() override; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the actions you are allowed to perform on the room. Actions allowedActions() const; + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns true if you are currently in the room. bool isJoined() const; + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the chat room's bare JID. QString jid() const; + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// + /// Returns the chat room's human-readable name. + /// + /// This name will only be available after the room has been joined. + /// QString name() const; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns your own nickname. QString nickName() const; void setNickName(const QString &nickName); Q_INVOKABLE QString participantFullJid(const QString &jid) const; QXmppPresence participantPresence(const QString &jid) const; + + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// + /// Returns the list of participant JIDs. + /// + /// These JIDs are Occupant JIDs of the form "room@service/nick". + /// QStringList participants() const; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the chat room password. QString password() const; void setPassword(const QString &password); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the room's subject. QString subject() const; void setSubject(const QString &subject); diff --git a/src/client/QXmppTransferManager.cpp b/src/client/QXmppTransferManager.cpp index 76d69b10..098e8d6b 100644 --- a/src/client/QXmppTransferManager.cpp +++ b/src/client/QXmppTransferManager.cpp @@ -284,33 +284,24 @@ void QXmppTransferJob::accept(QIODevice *iodevice) } } -/// Returns the job's transfer direction. -/// - QXmppTransferJob::Direction QXmppTransferJob::direction() const { return d->direction; } +/// /// Returns the last error that was encountered. /// - QXmppTransferJob::Error QXmppTransferJob::error() const { return d->error; } -/// Returns the remote party's JID. -/// - QString QXmppTransferJob::jid() const { return d->jid; } -/// Returns the local file URL. -/// - QUrl QXmppTransferJob::localFileUrl() const { return d->localFileUrl; @@ -359,9 +350,6 @@ qint64 QXmppTransferJob::fileSize() const } /// \endcond -/// Returns the job's transfer method. -/// - QXmppTransferJob::Method QXmppTransferJob::method() const { return d->method; @@ -388,9 +376,6 @@ qint64 QXmppTransferJob::speed() const return (d->done * 1000.0) / elapsed; } -/// Returns the job's state. -/// - QXmppTransferJob::State QXmppTransferJob::state() const { return d->state; @@ -1483,10 +1468,6 @@ void QXmppTransferManager::streamInitiationSetReceived(const QXmppStreamInitiati emit fileReceived(job); } -/// Return the JID of the bytestream proxy to use for -/// outgoing transfers. -/// - QString QXmppTransferManager::proxy() const { return d->proxy; @@ -1505,10 +1486,6 @@ void QXmppTransferManager::setProxy(const QString &proxyJid) d->proxy = proxyJid; } -/// Return whether the proxy will systematically be used for -/// outgoing SOCKS5 bytestream transfers. -/// - bool QXmppTransferManager::proxyOnly() const { return d->proxyOnly; @@ -1526,11 +1503,6 @@ void QXmppTransferManager::setProxyOnly(bool proxyOnly) d->proxyOnly = proxyOnly; } -/// Return the supported stream methods. -/// -/// The methods are a combination of zero or more QXmppTransferJob::Method. -/// - QXmppTransferJob::Methods QXmppTransferManager::supportedMethods() const { return d->supportedMethods; diff --git a/src/client/QXmppTransferManager.h b/src/client/QXmppTransferManager.h index 0c48b8b8..84f7278b 100644 --- a/src/client/QXmppTransferManager.h +++ b/src/client/QXmppTransferManager.h @@ -87,13 +87,20 @@ class QXMPP_EXPORT QXmppTransferJob : public QXmppLoggable { Q_OBJECT Q_FLAGS(Method Methods) + /// The job's transfer direction Q_PROPERTY(Direction direction READ direction CONSTANT) + /// The local file URL Q_PROPERTY(QUrl localFileUrl READ localFileUrl WRITE setLocalFileUrl NOTIFY localFileUrlChanged) + /// The remote party's JID Q_PROPERTY(QString jid READ jid CONSTANT) + /// The job's transfer method Q_PROPERTY(Method method READ method CONSTANT) + /// The job's state Q_PROPERTY(State state READ state NOTIFY stateChanged) + /// The name of the file Q_PROPERTY(QString fileName READ fileName CONSTANT) + /// The size of the file Q_PROPERTY(qint64 fileSize READ fileSize CONSTANT) public: @@ -135,16 +142,24 @@ public: ~QXmppTransferJob() override; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the job's transfer direction. QXmppTransferJob::Direction direction() const; - QXmppTransferJob::Error error() const; + /// Returns the remote party's JID. QString jid() const; + /// Returns the job's transfer method. QXmppTransferJob::Method method() const; + /// Returns the job's state. + QXmppTransferJob::State state() const; + + QXmppTransferJob::Error error() const; QString sid() const; qint64 speed() const; - QXmppTransferJob::State state() const; // XEP-0096 : File transfer QXmppTransferFileInfo fileInfo() const; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the local file URL. QUrl localFileUrl() const; void setLocalFileUrl(const QUrl &localFileUrl); @@ -218,20 +233,33 @@ private: class QXMPP_EXPORT QXmppTransferManager : public QXmppClientExtension { Q_OBJECT + + /// The JID of the bytestream proxy to use for outgoing transfers Q_PROPERTY(QString proxy READ proxy WRITE setProxy) + /// Whether the proxy will systematically be used for outgoing SOCKS5 bytestream transfers Q_PROPERTY(bool proxyOnly READ proxyOnly WRITE setProxyOnly) + /// The supported stream methods Q_PROPERTY(QXmppTransferJob::Methods supportedMethods READ supportedMethods WRITE setSupportedMethods) public: QXmppTransferManager(); ~QXmppTransferManager() override; + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Return the JID of the bytestream proxy to use for outgoing transfers. QString proxy() const; void setProxy(const QString &proxyJid); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Return whether the proxy will systematically be used for outgoing + /// SOCKS5 bytestream transfers. bool proxyOnly() const; void setProxyOnly(bool proxyOnly); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Return the supported stream methods. + /// + /// The methods are a combination of zero or more QXmppTransferJob::Method. QXmppTransferJob::Methods supportedMethods() const; void setSupportedMethods(QXmppTransferJob::Methods methods); diff --git a/src/server/QXmppServer.cpp b/src/server/QXmppServer.cpp index 2ee38fa6..da018389 100644 --- a/src/server/QXmppServer.cpp +++ b/src/server/QXmppServer.cpp @@ -363,9 +363,6 @@ void QXmppServer::setDomain(const QString &domain) d->domain = domain; } -/// Returns the QXmppLogger associated with the server. -/// - QXmppLogger *QXmppServer::logger() { return d->logger; diff --git a/src/server/QXmppServer.h b/src/server/QXmppServer.h index 609886f8..ce0e456a 100644 --- a/src/server/QXmppServer.h +++ b/src/server/QXmppServer.h @@ -59,6 +59,7 @@ class QXmppStream; class QXMPP_EXPORT QXmppServer : public QXmppLoggable { Q_OBJECT + /// The QXmppLogger associated with the server Q_PROPERTY(QXmppLogger *logger READ logger WRITE setLogger NOTIFY loggerChanged) public: @@ -71,6 +72,8 @@ public: QString domain() const; void setDomain(const QString &domain); + // documentation needs to be here, see https://stackoverflow.com/questions/49192523/ + /// Returns the QXmppLogger associated with the server. QXmppLogger *logger(); void setLogger(QXmppLogger *logger); |
