Public Member Functions | |
void | reset () |
void | trigger (float delay, const std::string &msg, bool reconnect) |
void | tick (float dtime, Server *server) |
std::wstring | getShutdownTimerMessage () const |
bool | isTimerRunning () const |
Public Attributes | |
bool | is_requested = false |
bool | should_reconnect = false |
std::string | message |
Private Attributes | |
float | m_timer = 0.0f |
Friends | |
class | TestServerShutdownState |
std::wstring Server::ShutdownState::getShutdownTimerMessage | ( | ) | const |
References duration_to_string(), and myround().
Referenced by Server::handleCommand_ClientReady().
|
inline |
References m_timer.
Referenced by Server::handleCommand_ClientReady(), and Server::requestShutdown().
void Server::ShutdownState::reset | ( | ) |
References is_requested, m_timer, message, and should_reconnect.
Referenced by Server::requestShutdown(), and TestServerShutdownState::testReset().
void Server::ShutdownState::tick | ( | float | dtime, |
Server * | server ) |
References ARRLEN, infostream, PEER_ID_INEXISTENT, and wide_to_utf8().
Referenced by Server::AsyncRunStep(), and TestServerShutdownState::testTick().
void Server::ShutdownState::trigger | ( | float | delay, |
const std::string & | msg, | ||
bool | reconnect ) |
Referenced by Server::requestShutdown(), TestServerShutdownState::testTick(), and TestServerShutdownState::testTrigger().
|
friend |
bool Server::ShutdownState::is_requested = false |
|
private |
std::string Server::ShutdownState::message |
bool Server::ShutdownState::should_reconnect = false |