MCPcopy Index your code
hub / github.com/clips/pattern / traverse

Method traverse

pattern/web/__init__.py:2658–2661  ·  view source on GitHub ↗

Executes the visit function on this node and each of its child nodes.

(self, visit=lambda node: None)

Source from the content-addressed store, hash-verified

2656 next, previous = next_sibling, previous_sibling
2657
2658 def traverse(self, visit=lambda node: None):
2659 """ Executes the visit function on this node and each of its child nodes.
2660 """
2661 visit(self); [node.traverse(visit) for node in self.children]
2662
2663 def __nonzero__(self):
2664 return True

Callers 3

test_node_traverseMethod · 0.45
test_clusterMethod · 0.45
test_hierarchicalMethod · 0.45

Calls

no outgoing calls

Tested by 3

test_node_traverseMethod · 0.36
test_clusterMethod · 0.36
test_hierarchicalMethod · 0.36