void System::update(float elapsedTime) { if (mState != SYSTEM_STATE_STARTED && mState != SYSTEM_STATE_UPDATED) return; mState = SYSTEM_STATE_UPDATING; if (mSystemDriver != nullptr) mSystemDriver->update(elapsedTime); updateImpl(elapsedTime); if (mState == SYSTEM_STATE_STOPING) { if (mSystemDriver != nullptr) mSystemDriver->stop(); stopImpl(); mState = SYSTEM_STATE_STOPED; if (Log::getInstance() != nullptr) Log::getInstance()->logMessage(mName, "Stoped"); } else { mState = SYSTEM_STATE_UPDATED; } }
void System::stop() { if (mState == SYSTEM_STATE_STOPED) return; if (mState != SYSTEM_STATE_UPDATING) { mState = SYSTEM_STATE_STOPING; if (Log::getInstance() != nullptr) Log::getInstance()->logMessage(mName, "Stoping"); if (mSystemDriver != nullptr) mSystemDriver->stop(); stopImpl(); mState = SYSTEM_STATE_STOPED; if (Log::getInstance() != nullptr) Log::getInstance()->logMessage(mName, "Stoped"); } else { mState = SYSTEM_STATE_STOPING; if (Log::getInstance() != nullptr) Log::getInstance()->logMessage(mName, "Stoping"); } }
Process::~Process(void) { #if defined(DUNE_SYS_HAS_FORK) stopImpl(); joinImpl(); m_pvt->~ProcessPrivate(); #endif }
void stop(void) { stopImpl(); }
void Process::stop() { m_stopped = true; stopImpl(); }