|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.neu.ccs.demeterf.compose.CompTraversal
public class CompTraversal
Traverses an Object structure using Functors: combined Function Classes that know what to do. The constructors take any number of Functors or unwrapped function objects. During traversal, the first function object is treated normally, possibly with a traversal argument. All others receive the previous Functor's result as a final combine argument.
See Compose
for an example.
Constructor Summary | |
---|---|
CompTraversal(FC... fs)
Create a Traversal that goes Everywhere using any number of function objects |
|
CompTraversal(FC[] fs,
Control c)
Create a Traversal with traversal control using any number of function objects |
|
CompTraversal(Functor... fs)
Create a Traversal that goes Everywhere using any number of Functors |
|
CompTraversal(Functor[] fs,
Control c)
Create a Traversal with traversal control, using any number of Functors |
Method Summary | ||
---|---|---|
java.lang.Object[] |
traverse(java.lang.Object o)
Do the Traversal... |
|
java.lang.Object[] |
traverse(java.lang.Object o,
java.lang.Object a)
Do the Traversal... |
|
|
traverseLast(java.lang.Object o)
Do the Traversal... |
|
|
traverseLast(java.lang.Object o,
java.lang.Object arg)
Do the Traversal... |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CompTraversal(Functor... fs)
public CompTraversal(Functor[] fs, Control c)
public CompTraversal(FC... fs)
public CompTraversal(FC[] fs, Control c)
Method Detail |
---|
public <T> T traverseLast(java.lang.Object o)
public <T> T traverseLast(java.lang.Object o, java.lang.Object arg)
public java.lang.Object[] traverse(java.lang.Object o)
public java.lang.Object[] traverse(java.lang.Object o, java.lang.Object a)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |