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.

101 lines
3.3 KiB

  1. //==============================================================;
  2. //
  3. // This source code is only intended as a supplement to existing Microsoft documentation.
  4. //
  5. //
  6. //
  7. //
  8. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
  9. // KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
  10. // IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
  11. // PURPOSE.
  12. //
  13. // Copyright (C) 1999 Microsoft Corporation. All Rights Reserved.
  14. //
  15. //
  16. //
  17. //==============================================================;
  18. #ifndef _SAMPCOMPDATA_H_
  19. #define _SAMPCOMPDATA_H_
  20. #include <mmc.h>
  21. #include "DeleBase.h"
  22. #include "StatNode.h"
  23. #include "Comp.h"
  24. class CComponentData : public IComponentData,
  25. IExtendContextMenu,
  26. ISnapinHelp
  27. {
  28. friend class CComponent;
  29. private:
  30. ULONG m_cref;
  31. LPCONSOLE m_ipConsole;
  32. LPCONSOLENAMESPACE m_ipConsoleNameSpace;
  33. CStaticNode *m_pStaticNode;
  34. WCHAR m_HelpFile[MAX_PATH];
  35. public:
  36. CComponentData();
  37. ~CComponentData();
  38. ///////////////////////////////
  39. // Interface IUnknown
  40. ///////////////////////////////
  41. STDMETHODIMP QueryInterface(REFIID riid, LPVOID *ppv);
  42. STDMETHODIMP_(ULONG) AddRef();
  43. STDMETHODIMP_(ULONG) Release();
  44. ///////////////////////////////
  45. // Interface IComponentData
  46. ///////////////////////////////
  47. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE Initialize(
  48. /* [in] */ LPUNKNOWN pUnknown);
  49. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE CreateComponent(
  50. /* [out] */ LPCOMPONENT __RPC_FAR *ppComponent);
  51. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE Notify(
  52. /* [in] */ LPDATAOBJECT lpDataObject,
  53. /* [in] */ MMC_NOTIFY_TYPE event,
  54. /* [in] */ LPARAM arg,
  55. /* [in] */ LPARAM param);
  56. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE Destroy( void);
  57. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE QueryDataObject(
  58. /* [in] */ MMC_COOKIE cookie,
  59. /* [in] */ DATA_OBJECT_TYPES type,
  60. /* [out] */ LPDATAOBJECT __RPC_FAR *ppDataObject);
  61. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE GetDisplayInfo(
  62. /* [out][in] */ SCOPEDATAITEM __RPC_FAR *pScopeDataItem);
  63. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE CompareObjects(
  64. /* [in] */ LPDATAOBJECT lpDataObjectA,
  65. /* [in] */ LPDATAOBJECT lpDataObjectB);
  66. ///////////////////////////////
  67. // Interface ISnapinHelp
  68. ///////////////////////////////
  69. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE GetHelpTopic(
  70. /* [out] */ LPOLESTR __RPC_FAR *lpCompiledHelpFile);
  71. ///////////////////////////////
  72. // Interface IExtendContextMenu
  73. ///////////////////////////////
  74. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE AddMenuItems(
  75. /* [in] */ LPDATAOBJECT piDataObject,
  76. /* [in] */ LPCONTEXTMENUCALLBACK piCallback,
  77. /* [out][in] */ long __RPC_FAR *pInsertionAllowed);
  78. virtual /* [helpstring] */ HRESULT STDMETHODCALLTYPE Command(
  79. /* [in] */ long lCommandID,
  80. /* [in] */ LPDATAOBJECT piDataObject);
  81. };
  82. #endif _SAMPCOMPDATA_H_