ReactOS  0.4.15-dev-506-ga3ec01c
CQITestObject Class Reference
Inheritance diagram for CQITestObject:
Collaboration diagram for CQITestObject:

Public Member Functions

 CQITestObject ()
 
 ~CQITestObject ()
 
 STDMETHOD_ (ULONG, AddRef)()
 
 STDMETHOD_ (ULONG, Release)()
 
STDMETHOD() QueryInterface (REFIID iid, void **ppvObject)
 
STDMETHOD() GetClassID (CLSID *pClassID)
 
STDMETHOD() GetClassForHandler (DWORD dwDestContext, void *pvDestContext, CLSID *pClsid)
 
- Public Member Functions inherited from IUnknown
ULONG AddRef ()
 
ULONG Release ()
 

Public Attributes

LONG m_dwRef
 

Additional Inherited Members

- Public Types inherited from IPersist
typedef IPersistLPPERSIST
 
- Public Types inherited from IUnknown
typedef IUnknownLPUNKNOWN
 
- Public Types inherited from IStdMarshalInfo
typedef IStdMarshalInfoLPSTDMARSHALINFO
 

Detailed Description

Definition at line 20 of file CComQIPtr.cpp.

Constructor & Destructor Documentation

◆ CQITestObject()

CQITestObject::CQITestObject ( )
inline

Definition at line 27 of file CComQIPtr.cpp.

28  :m_dwRef(1)
29  {
30  }

◆ ~CQITestObject()

CQITestObject::~CQITestObject ( )
inline

Definition at line 31 of file CComQIPtr.cpp.

32  {
33  }

Member Function Documentation

◆ GetClassForHandler()

STDMETHOD() CQITestObject::GetClassForHandler ( DWORD  dwDestContext,
void pvDestContext,
CLSID pClsid 
)
inline

Implements IStdMarshalInfo.

Definition at line 72 of file CComQIPtr.cpp.

73  {
74  return E_NOTIMPL;
75  }
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ GetClassID()

STDMETHOD() CQITestObject::GetClassID ( CLSID pClassID)
inline

Implements IPersist.

Definition at line 66 of file CComQIPtr.cpp.

67  {
68  return E_NOTIMPL;
69  }
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ QueryInterface()

STDMETHOD() CQITestObject::QueryInterface ( REFIID  iid,
void **  ppvObject 
)
inline

Implements IUnknown.

Definition at line 47 of file CComQIPtr.cpp.

48  {
50  if (iid == IID_IUnknown || iid == IID_IPersist)
51  {
52  AddRef();
53  *ppvObject = static_cast<IPersist*>(this);
54  return S_OK;
55  }
56  else if (iid == IID_IStdMarshalInfo)
57  {
58  AddRef();
59  *ppvObject = static_cast<IStdMarshalInfo*>(this);
60  return S_OK;
61  }
62  return E_NOINTERFACE;
63  }
#define E_NOINTERFACE
Definition: winerror.h:2364
const GUID IID_IPersist
Definition: proxy.cpp:14
static LONG g_QI
Definition: CComQIPtr.cpp:18
const GUID IID_IUnknown
ULONG AddRef()
REFIID LPVOID * ppvObject
Definition: precomp.h:44
#define S_OK
Definition: intsafe.h:59
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHOD_() [1/2]

CQITestObject::STDMETHOD_ ( ULONG  ,
AddRef   
)
inline

Definition at line 35 of file CComQIPtr.cpp.

36  {
38  return 2;
39  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHOD_() [2/2]

CQITestObject::STDMETHOD_ ( ULONG  ,
Release   
)
inline

Definition at line 41 of file CComQIPtr.cpp.

42  {
44  return 1;
45  }
#define InterlockedDecrement
Definition: armddk.h:52

Member Data Documentation

◆ m_dwRef

LONG CQITestObject::m_dwRef

Definition at line 25 of file CComQIPtr.cpp.

Referenced by START_TEST(), and STDMETHOD_().


The documentation for this class was generated from the following file: