no message
parent
74bfec54d5
commit
d42d5f1330
|
@ -233,7 +233,7 @@ int CProcessMonitor::StartLog(uint64_t milisecond){
|
|||
WORD wSecond = stTime.wSecond;
|
||||
CString m_date;
|
||||
//m_date字符串即为当前时间。如:2010年4月23日 11:12:45
|
||||
m_date.Format("%4d年%2d月%2d日 %2d:%2d:%2d", wYear, wMonth, wDay, wHour, wMinute, wSecond);
|
||||
m_date.Format("%4d-%2d-%2d %2d:%2d:%2d", wYear, wMonth, wDay, wHour, wMinute, wSecond);
|
||||
USES_CONVERSION;
|
||||
std::string strS(m_date); //CString-->std::string
|
||||
ProcessStatus *p = new ProcessStatus;
|
||||
|
|
|
@ -13,8 +13,10 @@ int main(int argc,char **argv){
|
|||
usage1.GetMemoryUsage(&pmem,&vmem);
|
||||
std::cout<<"cpu usage is "<< usage1.GetCpuUsage() << " "<<pmem <<
|
||||
"byte "<< vmem <<"byte seq "<< usage1.m_logs.size() << std::endl;
|
||||
|
||||
Sleep(1000);
|
||||
for(auto itr = usage1.m_logs.begin();itr != usage1.m_logs.end();itr++){
|
||||
std::cout<<(*itr)->time<<" "<<(*itr)->cpu;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue