diff options
| author | ilotterytea <iltsu@alright.party> | 2025-07-05 18:12:43 +0500 |
|---|---|---|
| committer | ilotterytea <iltsu@alright.party> | 2025-07-05 18:12:43 +0500 |
| commit | e39d90442dfd6fb136cda23b0d013da98fb089e9 (patch) | |
| tree | 56d31185d7f64536b1ba5047ceeb6791667d97c2 /bot/src/irc/message.hpp | |
| parent | 11ca4bf50b7b14b8be54756cb2a7f37ef31890a8 (diff) | |
feat: parse irc messages fully
Diffstat (limited to 'bot/src/irc/message.hpp')
| -rw-r--r-- | bot/src/irc/message.hpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/bot/src/irc/message.hpp b/bot/src/irc/message.hpp index 54b911b..ae903ba 100644 --- a/bot/src/irc/message.hpp +++ b/bot/src/irc/message.hpp @@ -14,6 +14,14 @@ namespace bot { enum MessageType { Privmsg, Ping, Notice }; std::optional<MessageType> define_message_type(const std::string &msg); + struct IRCMessage { + std::map<std::string, std::string> tags; + std::string prefix, nick, command; + std::vector<std::string> params; + + static std::optional<IRCMessage> from_string(std::string msg); + }; + struct MessageSender { std::string login; std::string display_name; |
