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.

53 lines
1.3 KiB

  1. //
  2. // MODULE: Event.h
  3. //
  4. // PURPOSE: Interface for class CEvent: Event Logging
  5. //
  6. // PROJECT: Generic Troubleshooter DLL for Microsoft AnswerPoint
  7. //
  8. // COMPANY: Saltmine Creative, Inc. (206)-284-7511 [email protected]
  9. //
  10. // AUTHOR: Roman Mach
  11. //
  12. // ORIGINAL DATE: 8-2-96
  13. //
  14. // NOTES:
  15. //
  16. // Version Date By Comments
  17. //--------------------------------------------------------------------
  18. // V3.0 9/18/98 JM Abstracted as a class. Previously, global.
  19. //
  20. //////////////////////////////////////////////////////////////////////
  21. #if !defined(AFX_EVENT_H__C3B8EE73_4F15_11D2_95F9_00C04FC22ADD__INCLUDED_)
  22. #define AFX_EVENT_H__C3B8EE73_4F15_11D2_95F9_00C04FC22ADD__INCLUDED_
  23. #if _MSC_VER >= 1000
  24. #pragma once
  25. #endif // _MSC_VER >= 1000
  26. #include "apgtsevt.h"
  27. #include "ApgtsCounters.h"
  28. // event name (goes under application to form a registry key)
  29. #define REG_EVT_ITEM_STR _T("APGTS")
  30. class CEvent
  31. {
  32. friend class CRegistryMonitor; // just so this can set m_bLogAll
  33. private:
  34. static bool s_bUseEventLog;
  35. static bool s_bLogAll;
  36. static CAbstractCounter * const s_pcountErrors;
  37. public:
  38. static void SetUseEventLog(bool bUseEventLog);
  39. static void ReportWFEvent(
  40. LPCTSTR string1,
  41. LPCTSTR string2,
  42. LPCTSTR string3,
  43. LPCTSTR string4,
  44. DWORD eventID);
  45. };
  46. #endif // !defined(AFX_EVENT_H__C3B8EE73_4F15_11D2_95F9_00C04FC22ADD__INCLUDED_)