17#ifdef PIKA_DEVELOPMENT
18 logInternally(l, type);
27 auto time = std::chrono::system_clock::to_time_t(std::chrono::system_clock::now());
29 s <<
"#" << std::put_time(std::localtime(&time),
"%Y-%m-%d %X");
51 std::ofstream file(name);
60 if (internalLogs.size() >= maxInternalLogCount)
62 internalLogs.pop_front();
65 internalLogs.push_back(
formatLog(l, type).str());
71 std::ofstream file(fileName, std::ofstream::app);
72 if (!file.is_open()) {
return; }
std::stringstream formatLog(const char *l, int type)
void logToFile(const char *fileName, const char *l, int type=samurai::logNormal)
void logInternally(const char *l, int type=samurai::logNormal)
void logToFile(const char *l, int type=samurai::logNormal)
void log(const char *l, int type=samurai::logNormal)
void init(std::string name)