6 LogNT* LogNT::instance = NULL;
18 LogNT* LogNT::getInstance()
23 bool LogNT::init(const std::string& tfileName, bool tenabled)
25 if (!tenabled) return true;
27 if (enabled) return true;
29 fileName = tfileName; // Keep the filename for later?
30 if (!fileName.compare("stdout"))
32 outstream = &std::cout;
38 logFile.open(fileName, std::ios_base::out | std::ios_base::app);
39 if (!logFile.is_open()) return false;
45 void LogNT::shutdown()
49 traceOnlyMode = false;
50 info("LOG", "Shutting down... bye!\n\n");
53 if (logFile.is_open()) logFile.close();
56 void LogNT::setTraceOnlyMode(bool t)