public class JavaASTCollector extends JavaASTWalker
| Modifier and Type | Field and Description | 
|---|---|
private ImmutableList<ProgramElement> | 
resultList
the list of found elements 
 | 
private java.lang.Class<?> | 
type
the type of nodes to be collected 
 | 
| Constructor and Description | 
|---|
JavaASTCollector(ProgramElement root,
                java.lang.Class<?> type)
create the JavaASTWalker 
 | 
| Modifier and Type | Method and Description | 
|---|---|
protected void | 
doAction(ProgramElement node)
the action that is performed just before leaving the node the
 last time 
 | 
ImmutableList<ProgramElement> | 
getNodes()
returns the found nodes of the specified type 
 | 
depth, root, start, walkprivate java.lang.Class<?> type
private ImmutableList<ProgramElement> resultList
public JavaASTCollector(ProgramElement root, java.lang.Class<?> type)
root - the ProgramElement where to begintype - the Class representing the type of nodes that have
 to be collectedprotected void doAction(ProgramElement node)
doAction in class JavaASTWalkerpublic ImmutableList<ProgramElement> getNodes()