CoGetInterceptor function
Instantiates the appropriate interceptor for the specified interface to be intercepted and returns the newly created interceptor.
Syntax
HRESULT CoGetInterceptor(
_In_ REFIID iidIntercepted,
_In_ IUnknown *punkOuter,
_In_ REFIID iid,
_Out_ void **ppv
);
Parameters
- iidIntercepted [in]
-
A reference to the identifier of the interface for which an interceptor is to be returned.
- punkOuter [in]
-
If this parameter is NULL, the object is not being created as part of an aggregate. Otherwise, this parameter is a pointer to the aggregate object's IUnknown interface (the controlling IUnknown).
- iid [in]
-
A reference to the identifier of the interface desired on the interceptor.
- ppv [out]
-
The address of a pointer variable that receives the interface pointer requested in iid. Upon successful return, **ppv contains the requested interceptor pointer.
Return value
This function can return the following values.
| Return code | Description |
|---|---|
|
The function returned successfully. |
|
An unexpected error occurred. |
Requirements
|
Minimum supported client |
Windows 2000 Professional [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows 2000 Server [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|
See also