MCPcopy Index your code
hub / github.com/python/cpython / iter

Method iter

Lib/xml/etree/ElementTree.py:587–597  ·  view source on GitHub ↗

Create and return tree iterator for the root element. The iterator loops over all elements in this tree, in document order. *tag* is a string with the tag name to iterate over (default is to return all elements).

(self, tag=None)

Source from the content-addressed store, hash-verified

585 source.close()
586
587 def iter(self, tag=None):
588 """Create and return tree iterator for the root element.
589
590 The iterator loops over all elements in this tree, in document order.
591
592 *tag* is a string with the tag name to iterate over
593 (default is to return all elements).
594
595 """
596 # assert self._root is not None
597 return self._root.iter(tag)
598
599 def find(self, path, namespaces=None):
600 """Find first matching element by tag name or path.

Callers

nothing calls this directly

Calls 1

iterMethod · 0.45

Tested by

no test coverage detected