1 #ifndef RKLOG_HEADER 2 #define RKLOG_HEADER 3 #include "DefineHeader.h" 4 5 class CRKLog 6 { 7 public: 8 bool GetEnableLog(); 9 void SetEnableLog(bool bEnable); 10 property<CRKLog, bool, READ_WRITE> EnableLog; 11 property<CRKLog, tstring, READ_ONLY> LogSavePath; 12 CRKLog(bool enable = true); 13 ~CRKLog(); 14 bool SaveBuffer(tstring fileName, PBYTE lpBuffer, DWORD dwSize); 15 void PrintBuffer(tstring &strOutput, PBYTE lpBuffer, DWORD dwSize, UINT uiLineCount = 16); 16 void Record(const tchar *lpFmt, ...); 17 18 protected: 19 private: 20 bool m_enable; 21 }; 22 23 #endif