MCPcopy Create free account
hub / github.com/ELMERIKH/PyinMemoryPE / QueryInterface

Method QueryInterface

windows/com.py:342–347  ·  view source on GitHub ↗

Default ``QueryInterface`` implementation that returns ``self`` if piid is the implemented interface

(self, this, piid, result)

Source from the content-addressed store, hash-verified

340 self._as_parameter_ = ctypes.addressof(self.vtable_pointer)
341
342 def QueryInterface(self, this, piid, result):
343 """Default ``QueryInterface`` implementation that returns ``self`` if piid is the implemented interface"""
344 if piid[0] in (gdef.IUnknown.IID, self.IMPLEMENT.IID):
345 result[0] = this
346 return 1
347 return E_NOINTERFACE
348
349 def AddRef(self, *args):
350 """Default ``AddRef`` implementation that returns ``1``"""

Callers 2

rulesMethod · 0.80
queryMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected