ICONNPT.H
上传用户:bangxh
上传日期:2007-01-31
资源大小:42235k
文件大小:1k
源码类别:

Windows编程

开发平台:

Visual C++

  1. /*
  2.  * ICONNPT.H
  3.  *
  4.  * Header for template IConnectionPoint implementation.
  5.  *
  6.  * Copyright (c)1993-1995 Microsoft Corporation, All Rights Reserved
  7.  *
  8.  * Kraig Brockschmidt, Microsoft
  9.  * Internet  :  kraigb@microsoft.com
  10.  * Compuserve:  >INTERNET:kraigb@microsoft.com
  11.  */
  12. #ifndef _ICONNPT_H_
  13. #define _ICONNPT_H_
  14. #define INC_CONTROLS
  15. #include <inole.h>
  16. class CConnectionPoint;
  17. typedef class CConnectionPoint *PCConnectionPoint;
  18. class CConnectionPoint : public IConnectionPoint
  19.     {
  20.     protected:
  21.         ULONG           m_cRef;      //Interface reference count
  22.         LPVOID          m_pObj;      //Backpointer to the object
  23.     public:
  24.         CConnectionPoint(LPVOID);
  25.         ~CConnectionPoint(void);
  26.         STDMETHODIMP QueryInterface(REFIID, LPVOID *);
  27.         STDMETHODIMP_(ULONG) AddRef(void);
  28.         STDMETHODIMP_(ULONG) Release(void);
  29.         STDMETHODIMP GetConnectionInterface(IID *);
  30.         STDMETHODIMP GetConnectionPointContainer
  31.             (IConnectionPointContainer **);
  32.         STDMETHODIMP Advise(LPUNKNOWN, DWORD *);
  33.         STDMETHODIMP Unadvise(DWORD);
  34.         STDMETHODIMP EnumConnections(LPENUMCONNECTIONS *);
  35.     };
  36. #endif //_ICONNPT_H_