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.

60 lines
2.4 KiB

  1. //---------------------------------------------------------------------------
  2. // RowsetSource.h : CVDRowsetSource header file
  3. //
  4. // Copyright (c) 1996 Microsoft Corporation, All Rights Reserved
  5. // Developed by Sheridan Software Systems, Inc.
  6. //---------------------------------------------------------------------------
  7. #ifndef __CVDROWSETSOURCE__
  8. #define __CVDROWSETSOURCE__
  9. class CVDNotifyDBEventsConnPtCont;
  10. class CVDRowsetSource : public CVDNotifier
  11. {
  12. protected:
  13. // Construction/Destruction
  14. CVDRowsetSource();
  15. virtual ~CVDRowsetSource();
  16. // Initialization
  17. HRESULT Initialize(IRowset * pRowset);
  18. public:
  19. BOOL IsRowsetValid(){return (m_pRowset && !m_bool.fRowsetReleased);}
  20. void SetRowsetReleasedFlag(){m_bool.fRowsetReleased = TRUE;}
  21. IRowset * GetRowset() const {return m_pRowset;}
  22. IAccessor * GetAccessor() const {return m_pAccessor;}
  23. IRowsetLocate * GetRowsetLocate() const {return m_pRowsetLocate;}
  24. IRowsetScroll * GetRowsetScroll() const {return m_pRowsetScroll;}
  25. IRowsetChange * GetRowsetChange() const {return m_pRowsetChange;}
  26. IRowsetUpdate * GetRowsetUpdate() const {return m_pRowsetUpdate;}
  27. IRowsetFind * GetRowsetFind() const {return m_pRowsetFind;}
  28. IRowsetInfo * GetRowsetInfo() const {return m_pRowsetInfo;}
  29. IRowsetIdentity * GetRowsetIdentity() const {return m_pRowsetIdentity;}
  30. protected:
  31. // Data members
  32. struct
  33. {
  34. WORD fInitialized : 1; // is rowset source initialized?
  35. WORD fRowsetReleased : 1; // have we received a rowset release notification
  36. } m_bool;
  37. IRowset * m_pRowset; // [mandatory] interface IRowset
  38. IAccessor * m_pAccessor; // [mandatory] interface IAccessor
  39. IRowsetLocate * m_pRowsetLocate; // [mandatory] interface IRowsetLocate
  40. IRowsetScroll * m_pRowsetScroll; // [optional] interface IRowsetScroll
  41. IRowsetChange * m_pRowsetChange; // [optional] interface IRowsetChange
  42. IRowsetUpdate * m_pRowsetUpdate; // [optional] interface IRowsetUpdate
  43. IRowsetFind * m_pRowsetFind; // [optional] interface IRowsetFind
  44. IRowsetInfo * m_pRowsetInfo; // [optional] interface IRowsetInfo
  45. IRowsetIdentity * m_pRowsetIdentity;// [optional] interface IRowsetIdentity
  46. };
  47. #endif //__CVDROWSETSOURCE__