|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sourceforge.cilib.container.visitor.Visitor<E> net.sourceforge.cilib.container.visitor.PrePostVisitor<E>
E
- The element type.public class PrePostVisitor<E>
Extension of the default Visitor to make pre and post visit operations possible.
An example of use would be on Tree containers, whereby the specific traversal would alter the order in which tree nodes are used.
Constructor Summary | |
---|---|
PrePostVisitor()
Create a new instance of PrePostVisitor. |
Method Summary | |
---|---|
void |
postVisit(E o)
Post-visit the given element. |
void |
preVisit(E o)
Pre-visit the given element. |
void |
visit(E o)
Visit the provided object. |
Methods inherited from class net.sourceforge.cilib.container.visitor.Visitor |
---|
isDone |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PrePostVisitor()
Method Detail |
---|
public void preVisit(E o)
o
- The object to pre-visit.public void visit(E o)
visit
in class Visitor<E>
o
- The object to visit.public void postVisit(E o)
o
- The element to post visit.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |