2025-01-23 12:46:52 -08:00
|
|
|
#include "irc_coroutine.hpp"
|
|
|
|
|
|
|
|
auto irc_coroutine::is_running() -> bool {
|
|
|
|
return promise().connection_ != nullptr;
|
|
|
|
}
|
|
|
|
auto irc_coroutine::exception() -> std::exception_ptr {
|
|
|
|
return promise().exception_;
|
|
|
|
}
|
|
|
|
|
|
|
|
auto irc_coroutine::start(Connection& connection) -> void {
|
|
|
|
promise().connection_ = connection.shared_from_this();
|
|
|
|
resume();
|
|
|
|
}
|
|
|
|
|
2025-01-24 14:48:15 -08:00
|
|
|
void wait_ircmsg::stop() {
|
|
|
|
ircmsg_slot_.disconnect();
|
|
|
|
}
|
|
|
|
|
|
|
|
void wait_timeout::stop() {
|
|
|
|
timer_.reset();
|
2025-01-23 12:46:52 -08:00
|
|
|
}
|