summaryrefslogtreecommitdiff
path: root/include/libsock/server/client.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/libsock/server/client.hpp')
-rw-r--r--include/libsock/server/client.hpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/libsock/server/client.hpp b/include/libsock/server/client.hpp
index 0579a38..f7d9889 100644
--- a/include/libsock/server/client.hpp
+++ b/include/libsock/server/client.hpp
@@ -43,7 +43,8 @@ class Client {
template <typename... Args>
bool write(std::format_string<Args...> fmt, Args &&...args);
- void run();
+ void resumeHistory();
+ void runLoop(bool resumeHistory = true, std::optional<std::function<std::any(const SRecvData &)>> cb = std::nullopt);
bool isValid();
@@ -61,7 +62,7 @@ class Client {
std::optional<std::string> m_szReading = std::nullopt;
- void recvLoop();
+ void recvLoop(std::optional<std::function<std::any(const SRecvData &)>> cb = std::nullopt);
friend class Clients;
};