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.

66 lines
1.5 KiB

  1. /**********************************************************************/
  2. /** Microsoft Windows/NT **/
  3. /** Copyright(c) Microsoft Corporation, 1997 - 1999 **/
  4. /**********************************************************************/
  5. /*
  6. rtrdata.h
  7. Implementation for router data objects in the MMC
  8. FILE HISTORY:
  9. */
  10. #ifndef _RTRDATA_H
  11. #define _RTRDATA_H
  12. #ifndef _COMPDATA_H_
  13. #include "compdata.h"
  14. #endif
  15. #ifndef _EXTRACT_H
  16. #include "extract.h"
  17. #endif
  18. class CRouterDataObject :
  19. public CDataObject
  20. {
  21. public:
  22. // Derived class should override this for custom behavior
  23. virtual HRESULT QueryGetMoreData(LPFORMATETC lpFormatEtc);
  24. virtual HRESULT GetMoreDataHere(LPFORMATETC lpFormatEtc, LPSTGMEDIUM lpMedium);
  25. public:
  26. // Construction/Destruction
  27. // Normal constructor
  28. CRouterDataObject()
  29. {
  30. DEBUG_INCREMENT_INSTANCE_COUNTER(CRouterDataObject);
  31. };
  32. virtual ~CRouterDataObject()
  33. {
  34. DEBUG_DECREMENT_INSTANCE_COUNTER(CRouterDataObject);
  35. };
  36. // Implementation
  37. public:
  38. static unsigned int m_cfComputerName;
  39. void SetComputerName(LPCTSTR pszComputerName);
  40. // This gets set if the data object is for the local machine
  41. static unsigned int m_cfComputerAddedAsLocal;
  42. void SetComputerAddedAsLocal(BOOL fLocal);
  43. private:
  44. HRESULT CreateComputerName(LPSTGMEDIUM lpMedium);
  45. CString m_stComputerName;
  46. HRESULT CreateComputerAddedAsLocal(LPSTGMEDIUM lpMedium);
  47. BOOL m_fComputerAddedAsLocal;
  48. };
  49. #endif