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.

55 lines
1.6 KiB

  1. // P3Users.h : Declaration of the CP3Users
  2. #ifndef __P3USERS_H_
  3. #define __P3USERS_H_
  4. #include "resource.h" // main symbols
  5. #include <POP3Server.h>
  6. /////////////////////////////////////////////////////////////////////////////
  7. // CP3Users
  8. class ATL_NO_VTABLE CP3Users :
  9. public CComObjectRootEx<CComSingleThreadModel>,
  10. public CComCoClass<CP3Users, &CLSID_P3Users>,
  11. public IDispatchImpl<IP3Users, &IID_IP3Users, &LIBID_P3ADMINLib>
  12. {
  13. public:
  14. CP3Users();
  15. virtual ~CP3Users();
  16. DECLARE_REGISTRY_RESOURCEID(IDR_P3USERS)
  17. DECLARE_PROTECT_FINAL_CONSTRUCT()
  18. BEGIN_COM_MAP(CP3Users)
  19. COM_INTERFACE_ENTRY(IP3Users)
  20. COM_INTERFACE_ENTRY(IDispatch)
  21. END_COM_MAP()
  22. // IP3Users
  23. public:
  24. STDMETHOD(RemoveEx)(/*[in]*/ BSTR bstrUserName);
  25. STDMETHOD(AddEx)(/*[in]*/ BSTR bstrUserName, BSTR bstrPassword);
  26. STDMETHOD(Remove)(/*[in]*/ BSTR bstrUserName);
  27. STDMETHOD(Add)(/*[in]*/ BSTR bstrUserName);
  28. STDMETHOD(get_Item)(/*[in]*/ VARIANT vIndex, /*[out, retval]*/ IP3User **ppIUser);
  29. STDMETHOD(get_Count)(/*[out, retval]*/ long *pVal);
  30. STDMETHOD(get__NewEnum)(/*[out, retval]*/ IEnumVARIANT* *ppIEnumVARIANT);
  31. // Implementation
  32. public:
  33. HRESULT Init( IUnknown *pIUnk, CP3AdminWorker *pAdminX, LPWSTR psDomainName );
  34. // Attributes
  35. protected:
  36. IUnknown *m_pIUnk;
  37. CP3AdminWorker *m_pAdminX; // This is the object that actually does all the work.
  38. WCHAR m_sDomainName[POP3_MAX_DOMAIN_LENGTH];
  39. int m_iCur; // Index of current user
  40. WIN32_FIND_DATA m_stFindData; // Current User
  41. HANDLE m_hfSearch;
  42. };
  43. #endif //__P3USERS_H_