X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcore%2Fcorebasichandler.h;h=7d0fcc62b726a8acbf67a7792dc57cccc1f15fa5;hp=2e468b79e95b182d4e5045ad167c6f248fbfc97e;hb=45a0d954542db252ceb62b61243ee5c2253383de;hpb=60ba221ec89296f4b66cbbab8b8d70673b92085a diff --git a/src/core/corebasichandler.h b/src/core/corebasichandler.h index 2e468b79..7d0fcc62 100644 --- a/src/core/corebasichandler.h +++ b/src/core/corebasichandler.h @@ -54,12 +54,43 @@ public: signals: void displayMsg(Message::Type, BufferInfo::Type, const QString &target, const QString &text, const QString &sender = "", Message::Flags flags = Message::None); - void putCmd(const QString &cmd, const QList ¶ms, const QByteArray &prefix = QByteArray()); - void putCmd(const QString &cmd, const QList> ¶ms, const QByteArray &prefix = QByteArray()); - void putRawLine(const QByteArray &msg); + + /** + * Sends the raw (encoded) line, adding to the queue if needed, optionally with higher priority. + * + * @see CoreNetwork::putRawLine() + */ + void putRawLine(const QByteArray &msg, const bool prepend = false); + + /** + * Sends the command with encoded parameters, with optional prefix or high priority. + * + * @see CoreNetwork::putCmd(const QString &cmd, const QList ¶ms, const QByteArray &prefix = QByteArray(), const bool prepend = false) + */ + void putCmd(const QString &cmd, const QList ¶ms, const QByteArray &prefix = QByteArray(), const bool prepend = false); + + /** + * Sends the command for each set of encoded parameters, with optional prefix or high priority. + * + * @see CoreNetwork::putCmd(const QString &cmd, const QList> ¶ms, const QByteArray &prefix = QByteArray(), const bool prepend = false) + */ + void putCmd(const QString &cmd, const QList> ¶ms, const QByteArray &prefix = QByteArray(), const bool prepend = false); protected: - void putCmd(const QString &cmd, const QByteArray ¶m, const QByteArray &prefix = QByteArray()); + /** + * Sends the command with one parameter, with optional prefix or high priority. + * + * @param[in] cmd Command to send, ignoring capitalization + * @param[in] param Parameter for the command, encoded within a QByteArray + * @param[in] prefix Optional command prefix + * @param[in] prepend + * @parmblock + * If true, the command is prepended into the start of the queue, otherwise, it's appended to + * the end. This should be used sparingly, for if either the core or the IRC server cannot + * maintain PING/PONG replies, the other side will close the connection. + * @endparmblock + */ + void putCmd(const QString &cmd, const QByteArray ¶m, const QByteArray &prefix = QByteArray(), const bool prepend = false); inline CoreNetwork *network() const { return _network; } inline CoreSession *coreSession() const { return _network->coreSession(); }