def _Build_CoClass(self, type_info_tuple):
info, infotype, doc, attr = type_info_tuple
# find the source and dispinterfaces for the coclass
child_infos = []
for j in range(attr[8]):
flags = info.GetImplTypeFlags(j)
try:
refType = info.GetRefTypeInfo(info.GetRefTypeOfImplType(j))
except pythoncom.com_error:
# Can't load a dependent typelib?
continue
refAttr = refType.GetTypeAttr()
child_infos.append( (info, refAttr.typekind, refType, refType.GetDocumentation(-1), refAttr, flags) )
# Done generating children - now the CoClass itself.
newItem = CoClassItem(info, attr, doc)
return newItem, child_infos
评论列表
文章目录