ircprivadapter.h
1 //------------------------------------------------------------------------------
2 // ircprivadapter.h
3 //------------------------------------------------------------------------------
4 //
5 // This library is free software; you can redistribute it and/or
6 // modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation; either
8 // version 2.1 of the License, or (at your option) any later version.
9 //
10 // This library is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 // Lesser General Public License for more details.
14 //
15 // You should have received a copy of the GNU Lesser General Public
16 // License along with this library; if not, write to the Free Software
17 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
18 // 02110-1301 USA
19 //
20 //------------------------------------------------------------------------------
21 // Copyright (C) 2010 "Zalewa" <zalewapl@gmail.com>
22 //------------------------------------------------------------------------------
23 #ifndef __IRCPRIVADAPTER_H__
24 #define __IRCPRIVADAPTER_H__
25 
26 #include "irc/ircchatadapter.h"
27 
33 {
34  Q_OBJECT
35 
36 public:
37  IRCPrivAdapter(IRCNetworkAdapter *pNetwork, const QString &recipient);
38 
39  AdapterType adapterType() const override
40  {
41  return PrivAdapter;
42  }
43 
44  void userChangesNickname(const QString &oldNickname, const QString &newNickname) override;
45  void userJoins(const QString &nickname, const QString &fullSignature) override;
46  void userLeaves(const QString &nickname, const QString &farewellMessage, IRCQuitType quitType) override;
47  void userModeChanges(const QString &nickname,
48  const QList<char> &addedFlags, const QList<char> &removedFlags) override
49  {
50  Q_UNUSED(nickname);
51  Q_UNUSED(addedFlags);
52  Q_UNUSED(removedFlags);
53  // This is ignored here.
54  }
55 };
56 
57 #endif
Interprets communication between the client and the IRC server.
AdapterType adapterType() const override
Gets adapter type for this adapter instance.
void userChangesNickname(const QString &oldNickname, const QString &newNickname) override
Use this to register the fact that user has changed his/hers nickname.
void userModeChanges(const QString &nickname, const QList< char > &addedFlags, const QList< char > &removedFlags) override
Use this to register the fact that user MODE flags have changed.
Handles chatting through IRC.
AdapterType
Defines all possible types of IRC adapters.
void userJoins(const QString &nickname, const QString &fullSignature) override
Use this to register the fact that user has joined the chat.
Class type that is used for private conversations with other users directly.
void userLeaves(const QString &nickname, const QString &farewellMessage, IRCQuitType quitType) override
Use this to register the fact that user has left the chat.