首页 / common / ArrayIter

ArrayIter

模块: oapy._oa._common 导入: from oapy._oa import _common

概览

ArrayIteroapy 中可用,可通过 _common 模块访问。

本页汇总 ArrayIter 当前在 oapy 中可用的 Python 接口。

详细说明

template class ArrayIter< I, T > This is a simple array based implementation of the IIter class。 It is templated for two parameters: the actual interface to use as the iteration interface (this is assumed to be an expansion of the IIter templated interface) and the implementation type to use to store the elements of the array (which must be polymorphic with the iteration type of "I")。 Note that IIter has an internal typedef, "Type", by which ArrayIter determines the iteration type of the IIter interface。 The second parameter is provided to allow for a different storage type for the array elements than the raw iteration type。 For example, if the IIter is an iterator of interface pointers, one often uses an array of SPtr's to store the elements in the array, aiding in the management of the pointer reference counts。

构造函数

_common.ArrayIter(initialCap=0)

obj = _common.ArrayIter(initialCap=0)

方法总览

状态 Python 调用
obj.next(objOut)
obj.reset()
obj.add(elem)

方法说明

obj.next(objOut)

绑定状态: 已绑定

Python 调用: obj.next(objOut)

Python 示例

from oapy._oa import _common

# assume obj is a ArrayIter
obj.next(objOut)

obj.reset()

绑定状态: 已绑定

Python 调用: obj.reset()

Python 示例

from oapy._oa import _common

# assume obj is a ArrayIter
obj.reset()

obj.add(elem)

绑定状态: 已绑定

Python 调用: obj.add(elem)

Python 示例

from oapy._oa import _common

# assume obj is a ArrayIter
obj.add(elem)