#include <defaultlog.h>
Default implementation of the BaseLog interface.
If LogToFile is passed to SetLogToMode(), then DefaultLog depends on the MemorySystem
Inherits Kaim::BaseLog.
Public Member Functions | |
virtual void | LogMessageVarg (LogMessageId messageId, const char *fmt, va_list argList) |
calls LogBuffer() More... | |
virtual void | ReleaseMemorySystemResources () |
This is called in Kaim::BaseSystem::Destroy() before Navigation memory system is destroyed. More... | |
void | SetLogToMode (LogToModeMask logToMode) |
close m_file More... | |
void | SetupLogFile (const char *logAbsPath, FileOpenerBase *fileOpener=nullptr) |
.GwNavLog will be appended to logAbsPath More... | |
virtual void | SetVisualDebugServer (VisualDebugServer *visualDebugServer) |
Beware, when running multiple worlds, the log from all worlds will be sent to this VisualDebugServer even if the VisualDebugServer is associated with 1 world. More... | |
Static Public Member Functions | |
static void | SetGlobalBaseLog (BaseLog *log) |
SetGlobalBaseLog(BaseLog* log) must be used instead of SetGlobalLog(Log* log) More... | |
|
virtual |
calls LogBuffer()
|
virtual |
This is called in Kaim::BaseSystem::Destroy() before Navigation memory system is destroyed.
So, implementations of BaseLog that allocated Kaim::BaseSystem resources (e.g. using KY_MALLOC or KY_NEW or Kaim::SysFile) must release these resources in this function. Otherwise, expect crashes.
Reimplemented from Kaim::BaseLog.
|
inlinestaticinherited |
SetGlobalBaseLog(BaseLog* log) must be used instead of SetGlobalLog(Log* log)
|
inline |
close m_file
Sets the output locations in which debug messages will be printed. logToMode is a bitmask composed of elements from the LogToMode enumeration.
void Kaim::DefaultLog::SetupLogFile | ( | const char * | logAbsPath, |
FileOpenerBase * | fileOpener = nullptr |
||
) |
.GwNavLog will be appended to logAbsPath
|
inlinevirtual |
Beware, when running multiple worlds, the log from all worlds will be sent to this VisualDebugServer even if the VisualDebugServer is associated with 1 world.
The SetVisualDebugServer() is called atuomatically by the first call to World::StartVisualDebug().
Implements Kaim::BaseLog.