18 assert (!sBaseFileName.empty());
20 m_sBaseFileName = sBaseFileName;
37 m_sList.push_back(sLine);
43 while (!m_sList.empty())
45 string sLine = m_sList.front();
47 if (fputs(sLine.c_str(), m_pFile) < 0)
65 string sLogFilename = m_sBaseFileName +
GetDateTime(
'_',
'_') +
".csv";
66 m_pFile = fopen (sLogFilename.c_str(),
"wb");
69 printf (
"Error opening file!\n");
78 struct tm *pNow = localtime (&t);
80 sprintf (buffer,
"%02d.%02d.%d%c%02d%c%02d%c%02d", pNow->tm_mday, (pNow->tm_mon + 1), (pNow->tm_year + 1900), seperator, pNow->tm_hour, timeSeperator, pNow->tm_min, timeSeperator, pNow->tm_sec);
82 return string(buffer);
CStringDump(std::string sBaseFileName)
void Add(std::string sLine)
std::string GetDateTime(char seperator, char timeSeperator)
string GetDateTime(char seperator, char timeSeperator)