cf.FieldList.count

FieldList.count(value)[source]

Return the number of occurrences of a value

Elements are compared with the cf.equals function.

fl.count(value) is equivalent to len([None for f in fl if cf.equals(value, f)]).

Parameters:
value :

The value to search for in the list.

Returns:
out : int

The number of occurrences of the value.

Previous topic

cf.FieldList.append

Next topic

cf.FieldList.extend

This Page