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.

126 lines
3.6 KiB

  1. //////////////////////////////////////////////////////////////////////////////
  2. // Copyright (c) 2002 Microsoft Corporation. All rights reserved.
  3. // Copyright (c) 2002 OSR Open Systems Resources, Inc.
  4. //
  5. // LogSession.h : interface of the CLogSession class
  6. //////////////////////////////////////////////////////////////////////////////
  7. #pragma once
  8. class CDisplayDlg;
  9. class CTraceSession
  10. {
  11. public:
  12. // constructor
  13. CTraceSession(ULONG TraceSessionID);
  14. // destructor
  15. ~CTraceSession();
  16. BOOL ProcessPdb();
  17. ULONG m_traceSessionID;
  18. CString m_tempDirectory;
  19. CString m_pdbFile;
  20. CStringArray m_tmfFile;
  21. CString m_tmfPath;
  22. CStringArray m_tmcFile;
  23. CString m_ctlFile;
  24. CStringArray m_controlGuid;
  25. CStringArray m_controlGuidFriendlyName;
  26. CStringArray m_formatGuid;
  27. BOOL m_bKernelLogger;
  28. };
  29. // forward reference
  30. class CLogSessionDlg;
  31. class CLogSession
  32. {
  33. public:
  34. // constructor
  35. CLogSession(ULONG LogSessionID, CLogSessionDlg *pLogSessionDlg);
  36. // destructor
  37. ~CLogSession();
  38. BOOL BeginTrace(BOOL bUseExisting = FALSE);
  39. BOOL UpdateSession(PEVENT_TRACE_PROPERTIES pQueryProperties);
  40. LONG EndTrace();
  41. VOID SetState(LOG_SESSION_STATE StateValue);
  42. INLINE VOID SetDisplayName(CString &DisplayName)
  43. {
  44. m_displayName = DisplayName;
  45. }
  46. INLINE CString & GetDisplayName()
  47. {
  48. return m_displayName;
  49. }
  50. INLINE CDisplayDlg* GetDisplayWnd()
  51. {
  52. return m_pDisplayDialog;
  53. }
  54. INLINE VOID SetDisplayWnd(CDisplayDlg *pDisplayDlg)
  55. {
  56. m_pDisplayDialog = pDisplayDlg;
  57. }
  58. INLINE LONG GetGroupID()
  59. {
  60. return m_groupID;
  61. }
  62. INLINE VOID SetGroupID(LONG GroupID)
  63. {
  64. m_groupID = GroupID;
  65. }
  66. INLINE LONG GetLogSessionID()
  67. {
  68. return m_logSessionID;
  69. }
  70. INLINE VOID SetLogSessionID(LONG LogSessionID)
  71. {
  72. m_logSessionID = LogSessionID;
  73. }
  74. INLINE TRACEHANDLE GetSessionHandle()
  75. {
  76. return m_sessionHandle;
  77. }
  78. INLINE VOID SetSessionHandle(TRACEHANDLE SessionHandle)
  79. {
  80. m_sessionHandle = SessionHandle;
  81. }
  82. // log session information
  83. BOOL m_bAppend;
  84. BOOL m_bRealTime;
  85. BOOL m_bWriteLogFile;
  86. CString m_logFileName;
  87. CString m_displayName; // Log session display name
  88. LONG m_logSessionID; // Log session identification number
  89. LONG m_groupID; // Group identification number
  90. EVENT_TRACE_LOGFILE m_evmFile; // struct used for trace processing in real-time thread
  91. CDisplayDlg *m_pDisplayDialog; // Dialog for trace output
  92. CStringArray m_logSessionValues;
  93. BOOL m_bTraceActive;
  94. BOOL m_bSessionActive;
  95. BOOL m_bGroupingTrace; // used for grouping and ungrouping
  96. BOOL m_bStoppingTrace;
  97. TRACEHANDLE m_sessionHandle; // Log session handle
  98. TRACEHANDLE m_traceHandle; // Trace event session handle
  99. CPtrArray m_traceSessionArray;
  100. BOOLEAN m_bDisplayExistingLogFileOnly;
  101. CLogSessionDlg *m_pLogSessionDlg;
  102. CString m_stateText;
  103. COLORREF m_titleTextColor;
  104. COLORREF m_titleBackgroundColor;
  105. };