The QueryInterface method implements the IUnknown QueryInterface method. Do not call the protected QueryInterface method directly. QueryInterface is called through the IUnknown interface to obtain an interface pointer for the interface identified by the IID parameter. If the owner object supports the requested interface, it is returned in the Obj parameter and QueryInterface returns S_OK. If the owner object does not support the interface, QueryInterface returns E_NOINTERFACE.
After successfully obtaining an interface by calling QueryInterface, clients should increase the reference count by calling the IUnknown _AddRef method.
Namespace: RefCount
Delphi |
public |
Parameters
IID
Type: TGUID
Obj
Type: System.Void
Type: HResult