diff --git a/chat_messages.hpp b/chat_messages.hpp index 4ebe687..ee9dd27 100644 --- a/chat_messages.hpp +++ b/chat_messages.hpp @@ -36,6 +36,9 @@ namespace chat std::string get_content() const { return _content; } + + size_t length() const + { return sizeof(char) + _content.size() + sizeof(char); } }; std::ostream& operator<<(std::ostream& os, const chat_message& msg)