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.

85 lines
2.9 KiB

  1. /*++
  2. Copyright (C) 1998-1999 Microsoft Corporation
  3. Module Name:
  4. smrootnd.h
  5. Abstract:
  6. This object is used to represent the Performance Logs and Alerts root node
  7. --*/
  8. #ifndef _CLASS_SMROOTNODE_
  9. #define _CLASS_SMROOTNODE_
  10. #include "smnode.h"
  11. #include "smctrsv.h"
  12. #include "smtracsv.h"
  13. #include "smalrtsv.h"
  14. class CSmRootNode : public CSmNode
  15. {
  16. // constructor/destructor
  17. public:
  18. CSmRootNode ();
  19. virtual ~CSmRootNode();
  20. // public methods
  21. public:
  22. virtual CSmRootNode* CastToRootNode( void ) { return this; };
  23. void Destroy( void );
  24. HSCOPEITEM GetScopeItemHandle ( void ) { return m_hRootNode; };
  25. void SetScopeItemHandle ( HSCOPEITEM hRootNode )
  26. { m_hRootNode = hRootNode; };
  27. HSCOPEITEM GetParentScopeItemHandle ( void ) { return m_hParentNode; };
  28. void SetParentScopeItemHandle ( HSCOPEITEM hParentNode )
  29. { m_hParentNode = hParentNode; };
  30. BOOL IsExpanded(){ return m_bIsExpanded; };
  31. void SetExpanded( BOOL bExp){ m_bIsExpanded = bExp; };
  32. BOOL IsExtension(){ return m_bIsExtension; };
  33. void SetExtension( BOOL bExtension){ m_bIsExtension = bExtension; };
  34. BOOL IsLogService ( MMC_COOKIE mmcCookie );
  35. BOOL IsAlertService ( MMC_COOKIE mmcCookie );
  36. BOOL IsLogQuery ( MMC_COOKIE mmcCookie );
  37. CSmCounterLogService* GetCounterLogService ( void )
  38. { return &m_CounterLogService; };
  39. CSmTraceLogService* GetTraceLogService ( void )
  40. { return &m_TraceLogService; };
  41. CSmAlertService* GetAlertService ( void )
  42. { return &m_AlertService; };
  43. DWORD UpdateServiceConfig();
  44. private:
  45. enum ePrivateValue {
  46. eResetDelaySeconds = 60,
  47. eRestartDelayMilliseconds = 0
  48. };
  49. HSCOPEITEM m_hRootNode; // Root node handle
  50. HSCOPEITEM m_hParentNode; // Parent node is NULL for standalone
  51. BOOL m_bIsExpanded;
  52. BOOL m_bIsExtension;
  53. CSmCounterLogService m_CounterLogService; // service object: 1 per component per node type
  54. CSmTraceLogService m_TraceLogService; // service object: 1 per component per node type
  55. CSmAlertService m_AlertService; // service object: 1 per component per node type
  56. };
  57. typedef CSmRootNode SLROOT;
  58. typedef CSmRootNode* PSROOT;
  59. #endif //_CLASS_SMROOTNODE_