Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.trapezium.vrml.visitor
Class ChildCounter  view ChildCounter download ChildCounter.java

java.lang.Object
  extended bycom.trapezium.pattern.Visitor
      extended bycom.trapezium.vrml.visitor.ChildCounter
All Implemented Interfaces:
java.io.Serializable

public class ChildCounter
extends com.trapezium.pattern.Visitor

Counts all children that aren't brackets or braces. Probably should get rid of this, can be done more simply.

Since:
1.0
Version:
1.1, 31 Oct 1997

Field Summary
(package private)  int childCount
           
 
Fields inherited from class com.trapezium.pattern.Visitor
dataSource, visitLevel
 
Constructor Summary
ChildCounter(com.trapezium.parse.TokenEnumerator v)
          class constructor
 
Method Summary
 int getChildCount()
          how many children VrmlElements were found?
 boolean visitObject(java.lang.Object a)
          visit an object, only down one level.
 
Methods inherited from class com.trapezium.pattern.Visitor
accepts, acceptsPassOne, acceptsPassTwo, done, getDataSource, isTwoPassVisitor, setDataSource, spacer, visit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

childCount

int childCount
Constructor Detail

ChildCounter

public ChildCounter(com.trapezium.parse.TokenEnumerator v)
class constructor

Method Detail

visitObject

public boolean visitObject(java.lang.Object a)
visit an object, only down one level.

"visitLevel" is handled by Visitor class, is incremented each time we drop down a level in the scene graph, and is decremented each time we go up a level in the scene graph.


getChildCount

public int getChildCount()
how many children VrmlElements were found?