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.

64 lines
1.6 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 2000.
  5. //
  6. // File: S A M P L E D E V I C E . H
  7. //
  8. // Contents: UPnP Device Host Sample Device
  9. //
  10. // Notes:
  11. //
  12. // Author: mbend 26 Sep 2000
  13. //
  14. //----------------------------------------------------------------------------
  15. #pragma once
  16. #include "InternetGatewayDevice.h"
  17. #include "dispimpl2.h"
  18. #include "resource.h" // main symbols
  19. #include "upnphost.h"
  20. #include "COSInfoService.h"
  21. #include "CWANCommonInterfaceConfigService.h"
  22. /////////////////////////////////////////////////////////////////////////////
  23. // CInternetGatewayDevice
  24. class ATL_NO_VTABLE CInternetGatewayDevice :
  25. public CComObjectRootEx<CComMultiThreadModel>,
  26. public IUPnPDeviceControl
  27. {
  28. public:
  29. DECLARE_REGISTRY_RESOURCEID(IDR_SAMPLE_DEVICE)
  30. DECLARE_PROTECT_FINAL_CONSTRUCT()
  31. BEGIN_COM_MAP(CInternetGatewayDevice)
  32. COM_INTERFACE_ENTRY(IUPnPDeviceControl)
  33. END_COM_MAP()
  34. public:
  35. CInternetGatewayDevice();
  36. // IUPnPDeviceControl methods
  37. STDMETHOD(Initialize)(
  38. /*[in]*/ BSTR bstrXMLDesc,
  39. /*[in]*/ BSTR bstrDeviceIdentifier,
  40. /*[in]*/ BSTR bstrInitString);
  41. STDMETHOD(GetServiceObject)(
  42. /*[in]*/ BSTR bstrUDN,
  43. /*[in]*/ BSTR bstrServiceId,
  44. /*[out, retval]*/ IDispatch ** ppdispService);
  45. HRESULT FinalConstruct(void);
  46. HRESULT FinalRelease(void);
  47. CComObject<COSInfoService>* m_pOSInfoService;
  48. CComObject<CWANCommonInterfaceConfigService>* m_pWANCommonInterfaceConfigService;
  49. private:
  50. };