walk

open fun walk(traversal: Node.TreeTraversal, consumer: Consumer<Node>)(source)

Walks the AST, calling the consumer for every node, with traversal algorithm "traversal". This is the most general walk method. All other walk and findAll methods are based on this.


open fun walk(consumer: Consumer<Node>)(source)

Walks the AST, calling the consumer for every node with pre-order traversal.


open fun <T : Node?> walk(nodeType: Class<T>, consumer: Consumer<T>)(source)

Walks the AST with pre-order traversal, calling the consumer for every node of type "nodeType".