ReactOS  0.4.14-dev-376-gaedba84
CClassFactory Class Reference
Inheritance diagram for CClassFactory:
Collaboration diagram for CClassFactory:

Public Member Functions

STDMETHODIMP QueryInterface (REFIID InterfaceId, PVOID *Interface)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
HRESULT WINAPI CreateInstance (LPUNKNOWN pUnkOuter, REFIID riid, LPVOID *ppvObject)
 
HRESULT WINAPI LockServer (BOOL fLock)
 
 CClassFactory (LPFNCREATEINSTANCE lpfnCI, PLONG pcRefDll, IID *riidInst)
 
virtual ~CClassFactory ()
 
STDMETHODIMP QueryInterface (REFIID InterfaceId, PVOID *Interface)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
HRESULT WINAPI CreateInstance (LPUNKNOWN pUnkOuter, REFIID riid, LPVOID *ppvObject)
 
HRESULT WINAPI LockServer (BOOL fLock)
 
 CClassFactory (LPFNCREATEINSTANCE lpfnCI, PLONG pcRefDll, IID *riidInst)
 
virtual ~CClassFactory ()
 
STDMETHODIMP QueryInterface (REFIID InterfaceId, PVOID *Interface)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
HRESULT WINAPI CreateInstance (LPUNKNOWN pUnkOuter, REFIID riid, LPVOID *ppvObject)
 
HRESULT WINAPI LockServer (BOOL fLock)
 
 CClassFactory (LPFNCREATEINSTANCE lpfnCI, PLONG pcRefDll, IID *riidInst)
 
virtual ~CClassFactory ()
 
STDMETHODIMP QueryInterface (REFIID InterfaceId, PVOID *Interface)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
HRESULT WINAPI CreateInstance (LPUNKNOWN pUnkOuter, REFIID riid, LPVOID *ppvObject)
 
HRESULT WINAPI LockServer (BOOL fLock)
 
 CClassFactory (LPFNCREATEINSTANCE lpfnCI, PLONG pcRefDll, IID *riidInst)
 
virtual ~CClassFactory ()
 
- Public Member Functions inherited from IClassFactory
HRESULT CreateInstance ([in, unique] IUnknown *pUnkOuter, [in] REFIID riid, [out, iid_is(riid)] void **ppvObject)
 
HRESULT RemoteCreateInstance ([in] REFIID riid, [out, iid_is(riid)] IUnknown **ppvObject)
 
HRESULT RemoteLockServer ([in] BOOL fLock)
 
- Public Member Functions inherited from IUnknown
HRESULT QueryInterface ([in] REFIID riid, [out, iid_is(riid)] void **ppvObject)
 
ULONG AddRef ()
 
ULONG Release ()
 

Protected Attributes

LONG m_Ref
 
LPFNCREATEINSTANCE m_lpfnCI
 
IIDm_IID
 

Additional Inherited Members

- Public Types inherited from IClassFactory
typedef IClassFactoryLPCLASSFACTORY
 
- Public Types inherited from IUnknown
typedef IUnknownLPUNKNOWN
 

Detailed Description

Definition at line 14 of file classfactory.cpp.

Constructor & Destructor Documentation

◆ CClassFactory() [1/4]

CClassFactory::CClassFactory ( LPFNCREATEINSTANCE  lpfnCI,
PLONG  pcRefDll,
IID riidInst 
)
inline

Definition at line 38 of file classfactory.cpp.

38  : m_Ref(1), m_lpfnCI(lpfnCI), m_IID(riidInst)
39  {};
LPFNCREATEINSTANCE lpfnCI
Definition: shellole.c:61
LPFNCREATEINSTANCE m_lpfnCI

◆ ~CClassFactory() [1/4]

virtual CClassFactory::~CClassFactory ( )
inlinevirtual

Definition at line 41 of file classfactory.cpp.

41 {};

◆ CClassFactory() [2/4]

CClassFactory::CClassFactory ( LPFNCREATEINSTANCE  lpfnCI,
PLONG  pcRefDll,
IID riidInst 
)
inline

Definition at line 36 of file classfactory.cpp.

36  : m_Ref(1), m_lpfnCI(lpfnCI), m_IID(riidInst)
37  {};
LPFNCREATEINSTANCE lpfnCI
Definition: shellole.c:61
LPFNCREATEINSTANCE m_lpfnCI

◆ ~CClassFactory() [2/4]

virtual CClassFactory::~CClassFactory ( )
inlinevirtual

Definition at line 39 of file classfactory.cpp.

39 {};

◆ CClassFactory() [3/4]

CClassFactory::CClassFactory ( LPFNCREATEINSTANCE  lpfnCI,
PLONG  pcRefDll,
IID riidInst 
)
inline

Definition at line 38 of file classfactory.cpp.

38  : m_Ref(1), m_lpfnCI(lpfnCI), m_IID(riidInst)
39  {};
LPFNCREATEINSTANCE lpfnCI
Definition: shellole.c:61
LPFNCREATEINSTANCE m_lpfnCI

◆ ~CClassFactory() [3/4]

virtual CClassFactory::~CClassFactory ( )
inlinevirtual

Definition at line 41 of file classfactory.cpp.

41 {};

◆ CClassFactory() [4/4]

CClassFactory::CClassFactory ( LPFNCREATEINSTANCE  lpfnCI,
PLONG  pcRefDll,
IID riidInst 
)
inline

Definition at line 38 of file classfactory.cpp.

38  : m_Ref(1), m_lpfnCI(lpfnCI), m_IID(riidInst)
39  {};
LPFNCREATEINSTANCE lpfnCI
Definition: shellole.c:61
LPFNCREATEINSTANCE m_lpfnCI

◆ ~CClassFactory() [4/4]

virtual CClassFactory::~CClassFactory ( )
inlinevirtual

Definition at line 41 of file classfactory.cpp.

41 {};

Member Function Documentation

◆ CreateInstance() [1/4]

HRESULT WINAPI CClassFactory::CreateInstance ( LPUNKNOWN  pUnkOuter,
REFIID  riid,
LPVOID ppvObject 
)

◆ CreateInstance() [2/4]

HRESULT WINAPI CClassFactory::CreateInstance ( LPUNKNOWN  pUnkOuter,
REFIID  riid,
LPVOID ppvObject 
)

Definition at line 67 of file classfactory.cpp.

71 {
72  *ppvObject = NULL;
73 
75  {
76  return m_lpfnCI(pUnkOuter, riid, ppvObject);
77  }
78 
79  return E_NOINTERFACE;
80 }
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
LPFNCREATEINSTANCE m_lpfnCI
smooth NULL
Definition: ftsmooth.c:416
const GUID IID_IUnknown
REFIID LPVOID * ppvObject
Definition: precomp.h:44
#define IsEqualCLSID(rclsid1, rclsid2)
Definition: guiddef.h:96

◆ CreateInstance() [3/4]

HRESULT WINAPI CClassFactory::CreateInstance ( LPUNKNOWN  pUnkOuter,
REFIID  riid,
LPVOID ppvObject 
)

◆ CreateInstance() [4/4]

HRESULT WINAPI CClassFactory::CreateInstance ( LPUNKNOWN  pUnkOuter,
REFIID  riid,
LPVOID ppvObject 
)

◆ LockServer() [1/4]

HRESULT WINAPI CClassFactory::LockServer ( BOOL  fLock)

Implements IClassFactory.

◆ LockServer() [2/4]

HRESULT WINAPI CClassFactory::LockServer ( BOOL  fLock)

Implements IClassFactory.

Definition at line 84 of file classfactory.cpp.

86 {
87  return E_NOTIMPL;
88 }
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ LockServer() [3/4]

HRESULT WINAPI CClassFactory::LockServer ( BOOL  fLock)

Implements IClassFactory.

◆ LockServer() [4/4]

HRESULT WINAPI CClassFactory::LockServer ( BOOL  fLock)

Implements IClassFactory.

◆ QueryInterface() [1/4]

STDMETHODIMP CClassFactory::QueryInterface ( REFIID  InterfaceId,
PVOID Interface 
)

◆ QueryInterface() [2/4]

STDMETHODIMP CClassFactory::QueryInterface ( REFIID  InterfaceId,
PVOID Interface 
)

◆ QueryInterface() [3/4]

HRESULT WINAPI CClassFactory::QueryInterface ( REFIID  InterfaceId,
PVOID Interface 
)

Definition at line 51 of file classfactory.cpp.

54 {
55  *ppvObj = NULL;
57  {
58  *ppvObj = PVOID(this);
60  return S_OK;
61  }
62  return E_NOINTERFACE;
63 }
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
smooth NULL
Definition: ftsmooth.c:416
void * PVOID
Definition: retypes.h:9
const GUID IID_IUnknown
#define S_OK
Definition: intsafe.h:59
#define InterlockedIncrement
Definition: armddk.h:53
const GUID IID_IClassFactory
#define IsEqualIID(riid1, riid2)
Definition: guiddef.h:95

◆ QueryInterface() [4/4]

STDMETHODIMP CClassFactory::QueryInterface ( REFIID  InterfaceId,
PVOID Interface 
)

◆ STDMETHODIMP_() [1/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 16 of file classfactory.cpp.

17  {
19  return m_Ref;
20  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHODIMP_() [2/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 19 of file classfactory.cpp.

20  {
22  return m_Ref;
23  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHODIMP_() [3/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 19 of file classfactory.cpp.

20  {
22  return m_Ref;
23  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHODIMP_() [4/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 19 of file classfactory.cpp.

20  {
22  return m_Ref;
23  }
#define InterlockedIncrement
Definition: armddk.h:53

◆ STDMETHODIMP_() [5/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 21 of file classfactory.cpp.

22  {
24 
25  if (!m_Ref)
26  {
27  delete this;
28  return 0;
29  }
30  return m_Ref;
31  }
#define InterlockedDecrement
Definition: armddk.h:52

◆ STDMETHODIMP_() [6/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 24 of file classfactory.cpp.

25  {
27  if (!m_Ref)
28  {
29  delete this;
30  return 0;
31  }
32  return m_Ref;
33  }
#define InterlockedDecrement
Definition: armddk.h:52

◆ STDMETHODIMP_() [7/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 24 of file classfactory.cpp.

25  {
27  if (!m_Ref)
28  {
29  delete this;
30  return 0;
31  }
32  return m_Ref;
33  }
#define InterlockedDecrement
Definition: armddk.h:52

◆ STDMETHODIMP_() [8/8]

CClassFactory::STDMETHODIMP_ ( ULONG  )
inline

Definition at line 24 of file classfactory.cpp.

25  {
27  if (!m_Ref)
28  {
29  delete this;
30  return 0;
31  }
32  return m_Ref;
33  }
#define InterlockedDecrement
Definition: armddk.h:52

Member Data Documentation

◆ m_IID

IID * CClassFactory::m_IID
protected

Definition at line 46 of file classfactory.cpp.

Referenced by CreateInstance().

◆ m_lpfnCI

LPFNCREATEINSTANCE CClassFactory::m_lpfnCI
protected

Definition at line 45 of file classfactory.cpp.

Referenced by CreateInstance().

◆ m_Ref

LONG CClassFactory::m_Ref
protected

Definition at line 41 of file classfactory.cpp.

Referenced by QueryInterface(), and STDMETHODIMP_().


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