ReactOS 0.4.15-dev-7674-gc0b4db1
CVfdFactory Class Reference

#include <vfdshcfact.h>

Inheritance diagram for CVfdFactory:
Collaboration diagram for CVfdFactory:

Public Member Functions

 CVfdFactory ()
 
 ~CVfdFactory ()
 
STDMETHODIMP QueryInterface (REFIID, LPVOID *)
 
 STDMETHODIMP_ (ULONG) AddRef()
 
 STDMETHODIMP_ (ULONG) Release()
 
STDMETHODIMP CreateInstance (LPUNKNOWN, REFIID, LPVOID *)
 
STDMETHODIMP LockServer (BOOL)
 
- 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 LockServer ([in] BOOL fLock)
 
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

ULONG m_cRefCnt
 

Additional Inherited Members

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

Detailed Description

Definition at line 18 of file vfdshcfact.h.

Constructor & Destructor Documentation

◆ CVfdFactory()

CVfdFactory::CVfdFactory ( )

Definition at line 25 of file vfdshcfact.cpp.

26{
27 VFDTRACE(0, ("CVfdFactory::CVfdFactory()\n"));
28
29 m_cRefCnt = 0L;
30
32}
ULONG m_cRefCnt
Definition: vfdshcfact.h:21
#define L(x)
Definition: ntvdm.h:50
#define VFDTRACE(LEVEL, STRING)
Definition: vfddbg.h:72
UINT g_cDllRefCnt

◆ ~CVfdFactory()

CVfdFactory::~CVfdFactory ( )

Definition at line 37 of file vfdshcfact.cpp.

38{
39 VFDTRACE(0, ("CVfdFactory::~CVfdFactory()\n"));
40
42}

Member Function Documentation

◆ CreateInstance()

STDMETHODIMP CVfdFactory::CreateInstance ( LPUNKNOWN  pUnkOuter,
REFIID  riid,
LPVOID ppvObj 
)

Definition at line 92 of file vfdshcfact.cpp.

96{
97 VFDTRACE(0, ("CVfdFactory::CreateInstance()\n"));
98
99 *ppvObj = NULL;
100
101 // Shell extensions typically don't support
102 // aggregation (inheritance)
103
104 if (pUnkOuter) {
106 }
107
108 // Create the main shell extension object.
109 // The shell will then call QueryInterface with IID_IShellExtInit
110 // -- this is how shell extensions are initialized.
111
112 LPCVFDSHEXT pVfdShExt = new CVfdShExt;
113
114 if (!pVfdShExt) {
115 return E_OUTOFMEMORY;
116 }
117
118 return pVfdShExt->QueryInterface(riid, ppvObj);
119}
STDMETHODIMP QueryInterface(REFIID, LPVOID *)
Definition: vfdshext.cpp:55
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define NULL
Definition: types.h:112
REFIID riid
Definition: atlbase.h:39
#define CLASS_E_NOAGGREGATION
Definition: winerror.h:2662

◆ LockServer()

STDMETHODIMP CVfdFactory::LockServer ( BOOL  fLock)

Implements IClassFactory.

Definition at line 121 of file vfdshcfact.cpp.

122{
123 VFDTRACE(0, ("CVfdFactory::LockServer()\n"));
125 return NOERROR;
126}
#define UNREFERENCED_PARAMETER(P)
Definition: ntbasedef.h:317
#define NOERROR
Definition: winerror.h:2354

◆ QueryInterface()

STDMETHODIMP CVfdFactory::QueryInterface ( REFIID  riid,
LPVOID ppv 
)

Definition at line 47 of file vfdshcfact.cpp.

50{
51 VFDTRACE(0, ("CVfdFactory::QueryInterface()\n"));
52
53 *ppv = NULL;
54
57 *ppv = (LPCLASSFACTORY)this;
58
59 AddRef();
60
61 return NOERROR;
62 }
63
64 return E_NOINTERFACE;
65}
const GUID IID_IUnknown
const GUID IID_IClassFactory
REFIID LPVOID * ppv
Definition: atlbase.h:39
IClassFactory * LPCLASSFACTORY
Definition: unknwn.idl:70
ULONG AddRef()
#define IsEqualIID(riid1, riid2)
Definition: guiddef.h:95
#define E_NOINTERFACE
Definition: winerror.h:2364

Referenced by DllGetClassObject().

◆ STDMETHODIMP_() [1/2]

CVfdFactory::STDMETHODIMP_ ( ULONG  )

◆ STDMETHODIMP_() [2/2]

CVfdFactory::STDMETHODIMP_ ( ULONG  )

Member Data Documentation

◆ m_cRefCnt

ULONG CVfdFactory::m_cRefCnt
protected

Definition at line 21 of file vfdshcfact.h.

Referenced by CVfdFactory(), and STDMETHODIMP_().


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