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.

37 lines
511 B

  1. /*
  2. * refcount.hpp - RefCount class description.
  3. */
  4. /* Types
  5. ********/
  6. /* Classes
  7. **********/
  8. class RefCount
  9. {
  10. private:
  11. ULONG m_ulcRef;
  12. public:
  13. RefCount(void);
  14. // Virtual destructor defers to destructor of derived class.
  15. virtual ~RefCount(void);
  16. // IUnknown methods
  17. ULONG STDMETHODCALLTYPE AddRef(void);
  18. ULONG STDMETHODCALLTYPE Release(void);
  19. // friends
  20. #ifdef DEBUG
  21. friend BOOL IsValidPCRefCount(const RefCount *pcrefcnt);
  22. #endif
  23. };
  24. DECLARE_STANDARD_TYPES(RefCount);