Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

76 lines
2.2 KiB

  1. /*++
  2. Copyright (C) 1998-1999 Microsoft Corporation
  3. Module Name:
  4. smctrqry.h
  5. Abstract:
  6. Class definitions for the counter log query.
  7. --*/
  8. #ifndef _CLASS_SMCTRQRY_
  9. #define _CLASS_SMCTRQRY_
  10. #include "smlogqry.h"
  11. class CSmCounterLogQuery : public CSmLogQuery
  12. {
  13. // constructor/destructor
  14. public:
  15. CSmCounterLogQuery( CSmLogService* );
  16. virtual ~CSmCounterLogQuery( void );
  17. // public methods
  18. public:
  19. virtual DWORD Open ( const CString& rstrName, HKEY hKeyQuery, BOOL bReadOnly);
  20. virtual DWORD Close ( void );
  21. virtual DWORD SyncWithRegistry( void );
  22. virtual BOOL GetLogTime(PSLQ_TIME_INFO pTimeInfo, DWORD dwFlags);
  23. virtual BOOL SetLogTime(PSLQ_TIME_INFO pTimeInfo, const DWORD dwFlags);
  24. virtual BOOL GetDefaultLogTime(SLQ_TIME_INFO& rTimeInfo, DWORD dwFlags);
  25. virtual DWORD GetLogType( void );
  26. LPCWSTR GetFirstCounter( void );
  27. LPCWSTR GetNextCounter( void );
  28. VOID ResetCounterList( void );
  29. BOOL AddCounter(LPCWSTR szCounterPath);
  30. virtual HRESULT LoadFromPropertyBag ( IPropertyBag*, IErrorLog* );
  31. virtual HRESULT SaveToPropertyBag ( IPropertyBag*, BOOL fSaveAllProps );
  32. virtual HRESULT LoadCountersFromPropertyBag ( IPropertyBag*, IErrorLog* );
  33. virtual HRESULT SaveCountersToPropertyBag ( IPropertyBag* );
  34. virtual HRESULT TranslateMSZCounterList( LPTSTR pszCounterList,
  35. LPTSTR pBuffer,
  36. LPDWORD pdwBufferSize,
  37. BOOL bFlag);
  38. virtual CSmCounterLogQuery* CastToCounterLogQuery ( void ) { return this; };
  39. // protected methods
  40. protected:
  41. virtual DWORD UpdateRegistry();
  42. // private member variables
  43. private:
  44. LPTSTR m_szNextCounter;
  45. DWORD m_dwCounterListLength; // in chars including MSZ null
  46. // Registry Values
  47. LPTSTR mr_szCounterList;
  48. };
  49. typedef CSmCounterLogQuery SLCTRQUERY;
  50. typedef CSmCounterLogQuery* PSLCTRQUERY;
  51. #endif //_CLASS_SMCTRQRY_