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.

72 lines
1.9 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1997.
  5. //
  6. // File: E N U M W . H
  7. //
  8. // Contents: Enumerator for RAS connections objects.
  9. //
  10. // Notes:
  11. //
  12. // Author: shaunco 2 Oct 1997
  13. //
  14. //----------------------------------------------------------------------------
  15. #pragma once
  16. #include "nmbase.h"
  17. #include "nmres.h"
  18. #include <rasapip.h>
  19. class ATL_NO_VTABLE CWanConnectionManagerEnumConnection :
  20. public CComObjectRootEx <CComMultiThreadModel>,
  21. public CComCoClass <CWanConnectionManagerEnumConnection,
  22. &CLSID_WanConnectionManagerEnumConnection>,
  23. public IEnumNetConnection
  24. {
  25. private:
  26. NETCONMGR_ENUM_FLAGS m_EnumFlags;
  27. RASENUMENTRYDETAILS* m_aRasEntryName;
  28. ULONG m_cRasEntryName;
  29. ULONG m_iNextRasEntryName;
  30. BOOL m_fDone;
  31. private:
  32. HRESULT
  33. HrNextOrSkip (
  34. IN ULONG celt,
  35. OUT INetConnection** rgelt,
  36. OUT ULONG* pceltFetched);
  37. public:
  38. CWanConnectionManagerEnumConnection () throw();
  39. ~CWanConnectionManagerEnumConnection () throw();
  40. DECLARE_REGISTRY_RESOURCEID(IDR_WAN_CONMAN_ENUM)
  41. BEGIN_COM_MAP(CWanConnectionManagerEnumConnection)
  42. COM_INTERFACE_ENTRY(IEnumNetConnection)
  43. END_COM_MAP()
  44. // IEnumNetConnection
  45. STDMETHOD (Next) (
  46. IN ULONG celt,
  47. OUT INetConnection** rgelt,
  48. OUT ULONG* pceltFetched);
  49. STDMETHOD (Skip) (
  50. IN ULONG celt);
  51. STDMETHOD (Reset) ();
  52. STDMETHOD (Clone) (
  53. OUT IEnumNetConnection** ppenum);
  54. public:
  55. static HRESULT CreateInstance (
  56. IN NETCONMGR_ENUM_FLAGS Flags,
  57. IN REFIID riid,
  58. OUT void** ppv);
  59. };