|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.enhydra.xml.dom.SimpleDOMTraversal
Simple DOM traverser that calls a handler for every node in the DOM tree.
Nested Class Summary | |
static interface |
SimpleDOMTraversal.Handler
Interface for node callback object. |
Field Summary | |
protected SimpleDOMTraversal.Handler |
fHandler
Handler object for the traversal |
Constructor Summary | |
SimpleDOMTraversal(SimpleDOMTraversal.Handler handler)
Constructor. |
Method Summary | |
static SimpleDOMTraversal |
getTraverser(SimpleDOMTraversal.Handler handler,
org.w3c.dom.Node node)
Factory method to create a traverser based on the type of a document. |
protected void |
processAttributes(org.w3c.dom.Node node)
Process the attributes of an element. |
protected void |
processChildren(org.w3c.dom.Node node)
Process the children of a node. |
void |
processDocumentType(org.w3c.dom.Document document)
Process a DocumentType attribute of a Document node, if it exists. |
protected void |
processDocumentTypeContents(org.w3c.dom.DocumentType documentType)
Process the contents of a DocumentType node, |
protected void |
processNode(org.w3c.dom.Node node)
Processing based on node type. |
void |
traverse(org.w3c.dom.Node root)
Traverse a DOM tree or subtree. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected SimpleDOMTraversal.Handler fHandler
Constructor Detail |
public SimpleDOMTraversal(SimpleDOMTraversal.Handler handler)
handler
- The object that will be called to handle each
node.Method Detail |
public void traverse(org.w3c.dom.Node root)
root
- The root of the DOM tree or subtree that is to
be traversed.protected void processChildren(org.w3c.dom.Node node)
protected void processAttributes(org.w3c.dom.Node node)
public void processDocumentType(org.w3c.dom.Document document)
protected void processDocumentTypeContents(org.w3c.dom.DocumentType documentType)
protected void processNode(org.w3c.dom.Node node)
public static SimpleDOMTraversal getTraverser(SimpleDOMTraversal.Handler handler, org.w3c.dom.Node node)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |