40 #include "OutputFileHandler.hpp"
120 static unsigned Level();
138 void Set(
unsigned level,
const std::string& rDirectory,
const std::string& rFileName=
"log.txt");
191 (*mpOutStream) << std::setprecision((
int)
mPrecision) << message << std::flush;
199 #define LOG(level, message) assert(level>0); if(level <= LogFile::Level()) { (*LogFile::Instance()) << message << "\n"; }
200 #define LOG_AND_COUT(level, message) {std::cout << message << std::endl << std::flush; LOG(level, message); }
void Set(unsigned level, const std::string &rDirectory, const std::string &rFileName="log.txt")
static const unsigned mMaxLoggingLevel
LogFile & operator<<(T message)
static LogFile * mpInstance
void SetPrecision(unsigned precision)
void WriteHeader(std::string simulationType="")
void WriteElapsedTime(std::string pre="")
static LogFile * Instance()
static unsigned MaxLoggingLevel()