Java 2 Platform
v1.3

edu.umich.visualsoar.util
Class CountingVisitor

java.lang.Object
  |
  +--edu.umich.visualsoar.util.Visitor
        |
        +--edu.umich.visualsoar.util.CountingVisitor

public class CountingVisitor
extends Visitor

This class follows the visitor pattern it is based on Object-Oriented Design patterns in C++, later converted to Java it counts the number of things that it visits and has an accessor function so the client can recieve the result


Field Summary
private  int count
           
 
Constructor Summary
CountingVisitor()
           
 
Method Summary
 int count()
           
 void visit(java.lang.Object o)
           
 
Methods inherited from class edu.umich.visualsoar.util.Visitor
isDone
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

count

private int count
Constructor Detail

CountingVisitor

public CountingVisitor()
Method Detail

count

public int count()

visit

public void visit(java.lang.Object o)
Specified by:
visit in class Visitor

Java 2 Platform
v1.3