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.

125 lines
3.0 KiB

  1. // Factory.h: interface for the CFactory class.
  2. //
  3. //////////////////////////////////////////////////////////////////////
  4. #if !defined(__MYFACTORY_H)
  5. #define __MYFACTORY_H
  6. #if _MSC_VER >= 1000
  7. #pragma once
  8. #endif // _MSC_VER >= 1000
  9. //////////////////////////////////////////////////////////////////////
  10. // Base Class Factory for HealthMon consumer and providers
  11. //////////////////////////////////////////////////////////////////////
  12. class CBaseFactory : public IClassFactory
  13. {
  14. public:
  15. CBaseFactory();
  16. virtual ~CBaseFactory();
  17. public:
  18. // IUnknown
  19. STDMETHODIMP QueryInterface(REFIID riid, LPVOID* ppv);
  20. STDMETHODIMP_(ULONG) AddRef(void);
  21. STDMETHODIMP_(ULONG) Release(void);
  22. //IClassFactory members
  23. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  24. STDMETHODIMP LockServer(BOOL);
  25. protected:
  26. ULONG m_cRef;
  27. };
  28. //////////////////////////////////////////////////////////////////////
  29. // Class Factory for Consumer (original agent)
  30. //////////////////////////////////////////////////////////////////////
  31. class CConsFactory : public CBaseFactory
  32. {
  33. public:
  34. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  35. };
  36. //////////////////////////////////////////////////////////////////////
  37. // Class Factories for Event Providers
  38. //////////////////////////////////////////////////////////////////////
  39. class CSystemEvtProvFactory : public CBaseFactory
  40. {
  41. public:
  42. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  43. };
  44. class CDataGroupEvtProvFactory : public CBaseFactory
  45. {
  46. public:
  47. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  48. };
  49. class CDataCollectorEvtProvFactory : public CBaseFactory
  50. {
  51. public:
  52. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  53. };
  54. class CDataCollectorPerInstanceEvtProvFactory : public CBaseFactory
  55. {
  56. public:
  57. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  58. };
  59. class CDataCollectorStatisticsEvtProvFactory : public CBaseFactory
  60. {
  61. public:
  62. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  63. };
  64. class CThresholdEvtProvFactory : public CBaseFactory
  65. {
  66. public:
  67. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  68. };
  69. //class CThresholdInstanceEvtProvFactory : public CBaseFactory
  70. //{
  71. //public:
  72. // STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  73. //};
  74. class CActionEvtProvFactory : public CBaseFactory
  75. {
  76. public:
  77. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  78. };
  79. class CActionTriggerEvtProvFactory : public CBaseFactory
  80. {
  81. public:
  82. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  83. };
  84. //////////////////////////////////////////////////////////////////////
  85. // Class Factories for Instance Provider
  86. //////////////////////////////////////////////////////////////////////
  87. class CInstProvFactory : public CBaseFactory
  88. {
  89. public:
  90. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  91. };
  92. //////////////////////////////////////////////////////////////////////
  93. // Class Factories for Method Provider
  94. //////////////////////////////////////////////////////////////////////
  95. class CMethProvFactory : public CBaseFactory
  96. {
  97. public:
  98. STDMETHODIMP CreateInstance(LPUNKNOWN, REFIID, LPVOID*);
  99. };
  100. #endif // !defined(__MYFACTORY_H)