Leaked source code of windows server 2003
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.

79 lines
2.3 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. DWORD TranslateCounterListToLocale();
  31. virtual HRESULT LoadFromPropertyBag ( IPropertyBag*, IErrorLog* );
  32. virtual HRESULT SaveToPropertyBag ( IPropertyBag*, BOOL fSaveAllProps );
  33. virtual HRESULT LoadCountersFromPropertyBag ( IPropertyBag*, IErrorLog* );
  34. virtual HRESULT SaveCountersToPropertyBag ( IPropertyBag* );
  35. virtual DWORD TranslateMSZCounterList(
  36. LPWSTR pszCounterList,
  37. LPWSTR pBuffer,
  38. LPDWORD pdwBufferSize,
  39. BOOL bFlag);
  40. virtual CSmCounterLogQuery* CastToCounterLogQuery ( void ) { return this; };
  41. // protected methods
  42. protected:
  43. virtual DWORD UpdateRegistry();
  44. // private member variables
  45. private:
  46. LPWSTR m_szNextCounter;
  47. DWORD m_dwCounterListLength; // in chars including MSZ null
  48. // Registry Values
  49. LPWSTR mr_szCounterList;
  50. BOOL m_bCounterListInLocale;
  51. };
  52. typedef CSmCounterLogQuery SLCTRQUERY;
  53. typedef CSmCounterLogQuery* PSLCTRQUERY;
  54. #endif //_CLASS_SMCTRQRY_