2013-05-16 15:43:24 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
interface PHPParser_NodeTraverserInterface
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Adds a visitor.
|
|
|
|
*
|
|
|
|
* @param PHPParser_NodeVisitor $visitor Visitor to add
|
|
|
|
*/
|
|
|
|
function addVisitor(PHPParser_NodeVisitor $visitor);
|
|
|
|
|
2013-09-20 14:39:42 +02:00
|
|
|
/**
|
|
|
|
* Removes an added visitor.
|
|
|
|
*
|
|
|
|
* @param PHPParser_NodeVisitor $visitor
|
|
|
|
*/
|
|
|
|
function removeVisitor(PHPParser_NodeVisitor $visitor);
|
|
|
|
|
2013-05-16 15:43:24 +02:00
|
|
|
/**
|
|
|
|
* Traverses an array of nodes using the registered visitors.
|
|
|
|
*
|
|
|
|
* @param PHPParser_Node[] $nodes Array of nodes
|
|
|
|
*
|
|
|
|
* @return PHPParser_Node[] Traversed array of nodes
|
|
|
|
*/
|
|
|
|
function traverse(array $nodes);
|
|
|
|
}
|
|
|
|
|