21 #ifndef GRT_DEBUG_LOG_HEADER
22 #define GRT_DEBUG_LOG_HEADER
25 #include "ObserverManager.h"
31 DebugLogMessage(std::string proceedingText =
"",std::string message =
""){
32 this->proceedingText = proceedingText;
33 this->message = message;
39 std::string getProceedingText()
const {
40 return proceedingText;
43 std::string getMessage()
const {
47 std::string proceedingText;
53 DebugLog(std::string proceedingText =
""){ setProceedingText(proceedingText); Log::loggingEnabledPtr = &debugLoggingEnabled; }
59 this->proceedingText = rhs.proceedingText;
60 this->writeProceedingText = rhs.writeProceedingText;
61 this->loggingEnabledPtr = &debugLoggingEnabled;
62 this->writeProceedingTextPtr = &writeProceedingText;
68 virtual bool loggingEnabled(){
return debugLoggingEnabled; }
71 static bool enableLogging(
bool loggingEnabled);
78 virtual void triggerCallback(
const std::string &message )
const{
79 observerManager.notifyObservers(
DebugLogMessage(proceedingText,message) );
84 static bool debugLoggingEnabled;
89 #endif //GRT_DEBUG_LOG_HEADER