* forgot something

This commit is contained in:
false_genesis 2009-04-20 19:16:44 +00:00
parent 722ff4d7db
commit 53e88fca44
2 changed files with 11 additions and 0 deletions

View File

@ -82,6 +82,15 @@ std::string getDateString(void)
return std::string(str);
}
std::string GetTimeString(void)
{
time_t t = time(NULL);
tm* aTm = localtime(&t);
char str[15];
sprintf(str,"%02d:%02d:%02d", aTm->tm_hour,aTm->tm_min,aTm->tm_sec);
return std::string(str);
}
uint64 toInt(std::string str)
{
if(str.empty())

View File

@ -1,3 +1,4 @@
#ifndef _TOOLS_H
#define _TOOLS_H
@ -14,6 +15,7 @@ std::string stringToUpper(std::string);
std::string stringToLower(std::string);
std::string toString(uint64);
std::string getDateString(void);
std::string GetTimeString(void);
uint64 toInt(std::string);
std::string toHexDump(uint8* array,uint32 size,bool spaces=true,uint32 per_line=0);
std::deque<std::string> GetFileList(std::string);