Note: This API is now obsolete.
Enables developers to provide a custom, managed implementation of the IUnknown::QueryInterface(REFIID riid, void **ppvObject) method.
Assemblies: System.Runtime.InteropServices (in System.Runtime.InteropServices.dll)
mscorlib (in mscorlib.dll)
Thetype exposes the following members.
This class permits advanced users to provide a customized managed implementation of the QueryInterface method.
Managed and native applications can use the customized implementation to return a specific interface for a specified interface ID, except for IID_IUnknown. That is, when QueryInterface is called, it will ignore custom implementations if its riid parameter is set to IID_IUnknown. However, you may still return IUnknown as the ppvObject.
Developers can provide custom implementations for all interfaces (except for IUnknown) if they define and implement a valid corresponding interface.
.NET FrameworkSupported in: 4.6, 4.5, 4
Obsolete (compiler warning) in 4.6
.NET Framework Client ProfileSupported in: 4
.NET for Windows Phone appsSupported in: Windows Phone Silverlight 8.1, Windows Phone Silverlight 8
Obsolete (compiler warning) in Windows Phone 8.1