0f88e4671df7154d77e12fa7858a4efe7ce8f31f
[yaffs-website] / vendor / nikic / php-parser / lib / PhpParser / NodeTraverserInterface.php
1 <?php
2
3 namespace PhpParser;
4
5 interface NodeTraverserInterface
6 {
7     /**
8      * Adds a visitor.
9      *
10      * @param NodeVisitor $visitor Visitor to add
11      */
12     function addVisitor(NodeVisitor $visitor);
13
14     /**
15      * Removes an added visitor.
16      *
17      * @param NodeVisitor $visitor
18      */
19     function removeVisitor(NodeVisitor $visitor);
20
21     /**
22      * Traverses an array of nodes using the registered visitors.
23      *
24      * @param Node[] $nodes Array of nodes
25      *
26      * @return Node[] Traversed array of nodes
27      */
28     function traverse(array $nodes);
29 }
30