20#define LOGERROR(MESSAGE) logger->append(small3d::LogLevel::loggererror, MESSAGE)
25#define LOGINFO(MESSAGE) logger->append(small3d::LogLevel::loggerinfo, MESSAGE)
30#if defined(DEBUG) || defined(_DEBUG) || !defined (NDEBUG)
31#define LOGDEBUG(MESSAGE) logger->append(small3d::LogLevel::loggerdebug, MESSAGE)
33#define LOGDEBUG(MESSAGE)
43 loggerinfo, loggerdebug, loggererror
74 void append(
const LogLevel level,
const std::string &message)
const;
91extern std::shared_ptr<small3d::Logger>
logger;
std::shared_ptr< small3d::Logger > logger
The logger object used by the logging macros.
Definition Logger.cpp:14
Used for logging through macros (LOGERROR, LOGDEBUG, LOGINFO)
Definition Logger.hpp:51
void append(const LogLevel level, const std::string &message) const
Appends a message to the logger.
Definition Logger.cpp:26
Logger()
Constructor with stream for output.
Definition Logger.cpp:18
~Logger()
Destructor.
Definition Logger.cpp:22
Definition BinaryFile.hpp:15
LogLevel
Possible logging levels.
Definition Logger.hpp:42
void initLogger()
Initialise the logger.
Definition Logger.cpp:64
void deleteLogger()
Destroy the logger.
Definition Logger.cpp:68