net.sf.swan.xml.input.tree
Class TreeAdapter

java.lang.Object
  |
  +--net.sf.swan.xml.input.event.ContextAdapter
        |
        +--net.sf.swan.xml.input.tree.TreeAdapter
All Implemented Interfaces:
ContextListener

public class TreeAdapter
extends ContextAdapter

Component that uses a TreeFactory to build a document fragment or other tree structure and passes the result to a TreeResultHandler.


Constructor Summary
TreeAdapter(TreeResultHandler resultHandler)
          Initializes the TreeAdapter with a default DOMTreeFactory.
TreeAdapter(TreeResultHandler resultHandler, TreeFactory factory)
           
TreeAdapter(TreeResultHandler resultHandler, TreeFactory factory, Selector prototype)
           
 
Method Summary
 void endElement(EndElementEvent event)
           
 void processingInstruction(ProcessingInstructionEvent piEvent)
           
 void startElement(StartElementEvent event)
           
 void text(TextEvent event)
           
 
Methods inherited from class net.sf.swan.xml.input.event.ContextAdapter
getErrorHandler
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TreeAdapter

public TreeAdapter(TreeResultHandler resultHandler)
Initializes the TreeAdapter with a default DOMTreeFactory.

TreeAdapter

public TreeAdapter(TreeResultHandler resultHandler,
                   TreeFactory factory)

TreeAdapter

public TreeAdapter(TreeResultHandler resultHandler,
                   TreeFactory factory,
                   Selector prototype)
Method Detail

startElement

public void startElement(StartElementEvent event)
                  throws EventContextException
Overrides:
startElement in class ContextAdapter

endElement

public void endElement(EndElementEvent event)
                throws EventContextException
Overrides:
endElement in class ContextAdapter

text

public void text(TextEvent event)
          throws EventContextException
Overrides:
text in class ContextAdapter

processingInstruction

public void processingInstruction(ProcessingInstructionEvent piEvent)
                           throws EventContextException
Overrides:
processingInstruction in class ContextAdapter