An interface to make all logging capabilities central. More...
Public Member Functions | |
Logger () noexcept | |
virtual | ~Logger () |
virtual void | log (StringView message, StringView className)=0 |
An interface to make all logging capabilities central.
A client will inherit from this class and override the log method to output messages wherever is needed. This class is the base of all loggers within the library. Using it, it is possible to reroute all messages logged by the engine as a whole, component per component.
|
noexcept |
Constructor.
|
virtual |
Destructor.
|
pure virtual |
The method called when a message has been logged. This method is the one to be implemented by the client code.
message | The message to log. |
className | A bonus information to help giving context for the message that has been logged. Typically, it will be the class name (a message from Texture unable to load for instance). |
Implemented in nkLog::FileLogger, and nkLog::ConsoleLogger.