org.jtool.jxplatform.dom
Class DomCounter

java.lang.Object
  extended byorg.jtool.jxplatform.dom.DomCounter

public class DomCounter
extends java.lang.Object

Counts the numbers of all elements and attributes in an XML document.

Author:
Katsuhisa Maruyama

Constructor Summary
DomCounter()
           
 
Method Summary
static void initNum()
          Resets the numbers of elements and attributes.
static void termNum()
          Displays the numbers of elements and attributes respectively.
static void visitNode(org.w3c.dom.Document doc)
          Visits all nodes existing in a DOM object tree.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DomCounter

public DomCounter()
Method Detail

initNum

public static void initNum()
Resets the numbers of elements and attributes.


termNum

public static void termNum()
Displays the numbers of elements and attributes respectively.


visitNode

public static void visitNode(org.w3c.dom.Document doc)
Visits all nodes existing in a DOM object tree.

Parameters:
doc - The root of a DOM object tree to be visited.