MCPcopy Create free account
hub / github.com/enthought/comtypes / ITypeLib

Class ITypeLib

comtypes/typeinfo.py:222–292  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

220
221
222class ITypeLib(IUnknown):
223 _iid_ = GUID("{00020402-0000-0000-C000-000000000046}")
224
225 # type-checking only methods use the default implementation that comtypes
226 # automatically creates for COM methods.
227 if TYPE_CHECKING:
228
229 def GetTypeInfoCount(self) -> int:
230 """Return the number of type informations"""
231 ...
232
233 def GetTypeInfo(self, index: int) -> "ITypeInfo":
234 """Load type info by index"""
235 ...
236
237 def GetTypeInfoType(self, index: int) -> int:
238 """Return the TYPEKIND of type information"""
239 ...
240
241 def GetTypeInfoOfGuid(self, guid: GUID) -> "ITypeInfo":
242 """Return type information for a guid"""
243 ...
244
245 def GetTypeComp(self) -> "ITypeComp":
246 """Return an ITypeComp pointer."""
247 ...
248
249 def GetDocumentation(
250 self, index: int
251 ) -> tuple[str, Optional[str], int, Optional[str]]:
252 """Return documentation for a type description."""
253 ...
254
255 def ReleaseTLibAttr(self, ptla: "_Pointer[TLIBATTR]") -> int:
256 """Release TLIBATTR"""
257 ...
258
259 def GetLibAttr(self) -> "TLIBATTR":
260 """Return type library attributes"""
261 return _deref_with_release(
262 self._GetLibAttr(), # type: ignore
263 self.ReleaseTLibAttr,
264 )
265
266 def IsName(self, name: str, lHashVal: int = 0) -> Optional[str]:
267 """Check if there is type information for this name.
268
269 Returns the name with capitalization found in the type
270 library, or None.
271 """
272 namebuf = create_unicode_buffer(name)
273 found = BOOL()
274 self.__com_IsName(namebuf, lHashVal, byref(found)) # type: ignore
275 if found.value:
276 return namebuf[:].split("\0", 1)[0] # type: ignore
277 return None
278
279 def FindName(

Callers

nothing calls this directly

Calls 1

GUIDClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…