MCPcopy Create free account
hub / github.com/mhammond/pywin32 / GetCount

Method GetCount

com/win32comext/shell/src/PyIObjectArray.cpp:32–46  ·  view source on GitHub ↗

@pymethod int|PyIObjectArray|GetCount|Returns number of objects in collection

Source from the content-addressed store, hash-verified

30
31// @pymethod int|PyIObjectArray|GetCount|Returns number of objects in collection
32PyObject *PyIObjectArray::GetCount(PyObject *self, PyObject *args)
33{
34 IObjectArray *pIOA = GetI(self);
35 if ( pIOA == NULL )
36 return NULL;
37 UINT cObjects;
38 HRESULT hr;
39 PY_INTERFACE_PRECALL;
40 hr = pIOA->GetCount( &cObjects );
41 PY_INTERFACE_POSTCALL;
42
43 if ( FAILED(hr) )
44 return PyCom_BuildPyException(hr, pIOA, IID_IObjectArray );
45 return PyLong_FromUnsignedLong(cObjects);
46}
47
48// @pymethod <o PyIUnknown>|PyIObjectArray|GetAt|Retrieves an item by zero-based index
49PyObject *PyIObjectArray::GetAt(PyObject *self, PyObject *args)

Callers 8

DoWildConnectMethod · 0.45
cleanupMethod · 0.45
reprMethod · 0.45
PyCControlBar_GetCountFunction · 0.45
reprMethod · 0.45
PyCListBox_get_countFunction · 0.45
PyCComboBox_get_countFunction · 0.45
DisplayItemFunction · 0.45

Calls 2

FAILEDFunction · 0.85
PyCom_BuildPyExceptionFunction · 0.85

Tested by

no test coverage detected