added code to handle a single connection

This commit is contained in:
fourtf
2018-07-16 17:23:41 +02:00
parent e51c5c692a
commit 3b3c5d8d75
18 changed files with 114 additions and 84 deletions
+2 -3
View File
@@ -17,13 +17,11 @@ public:
virtual ~AbstractIrcServer() = default;
// connection
IrcConnection *getReadConnection() const;
IrcConnection *getWriteConnection() const;
void connect();
void disconnect();
void sendMessage(const QString &channelName, const QString &message);
void sendRawMessage(const QString &rawMessage);
// channels
std::shared_ptr<Channel> getOrAddChannel(const QString &dirtyChannelName);
@@ -54,6 +52,7 @@ protected:
virtual std::shared_ptr<Channel> getCustomChannel(const QString &channelName);
virtual bool hasSeparateWriteConnection() const = 0;
virtual QString cleanChannelName(const QString &dirtyChannelName);
QMap<QString, std::weak_ptr<Channel>> channels;