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.

56 lines
2.3 KiB

  1. //--------------------------------------------------------------------------
  2. // EnumFold.h
  3. //--------------------------------------------------------------------------
  4. #pragma once
  5. //--------------------------------------------------------------------------
  6. // CEnumerateFolders
  7. //--------------------------------------------------------------------------
  8. class CEnumerateFolders : public IEnumerateFolders
  9. {
  10. public:
  11. //----------------------------------------------------------------------
  12. // CEnumerateFolders
  13. //----------------------------------------------------------------------
  14. CEnumerateFolders(void);
  15. ~CEnumerateFolders(void);
  16. //----------------------------------------------------------------------
  17. // IUnknown Members
  18. //----------------------------------------------------------------------
  19. STDMETHODIMP QueryInterface(REFIID riid, LPVOID *ppv);
  20. STDMETHODIMP_(ULONG) AddRef(void);
  21. STDMETHODIMP_(ULONG) Release(void);
  22. //----------------------------------------------------------------------
  23. // CEnumerateFolders Members
  24. //----------------------------------------------------------------------
  25. HRESULT Initialize(IDatabase *pDB, BOOL fSubscribed, FOLDERID idParent);
  26. //----------------------------------------------------------------------
  27. // IEnumerateFolders Members
  28. //----------------------------------------------------------------------
  29. STDMETHODIMP Next(ULONG cFetch, LPFOLDERINFO prgInfo, ULONG *pcFetched);
  30. STDMETHODIMP Skip(ULONG cItems);
  31. STDMETHODIMP Reset(void);
  32. STDMETHODIMP Clone(IEnumerateFolders **ppEnum);
  33. STDMETHODIMP Count(ULONG *pcItems);
  34. private:
  35. //----------------------------------------------------------------------
  36. // Private Methods
  37. //----------------------------------------------------------------------
  38. HRESULT _FreeFolderArray(void);
  39. private:
  40. //----------------------------------------------------------------------
  41. // Private Data
  42. //----------------------------------------------------------------------
  43. LONG m_cRef;
  44. FOLDERID m_idParent;
  45. BOOL m_fSubscribed;
  46. DWORD m_cFolders;
  47. DWORD m_iFolder;
  48. IDatabase *m_pDB;
  49. IStream *m_pStream;
  50. };