com.simonstl.moe.factory
Class SAXFactoryTree

java.lang.Object
  |
  +--org.xml.sax.helpers.XMLFilterImpl
        |
        +--com.simonstl.moe.factory.SAXFactory
              |
              +--com.simonstl.moe.factory.SAXFactoryTree
All Implemented Interfaces:
ComponentInputI, ComponentOutputI, org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler, org.xml.sax.ext.LexicalHandler, org.xml.sax.XMLFilter, org.xml.sax.XMLReader

public class SAXFactoryTree
extends SAXFactory
implements ComponentOutputI, ComponentInputI

The SAXFactoryTree class provides a relatively simple mechanism for creating new MOE components, hardwired to the components provided in the com.simonstl.moe package. It in turn relies on the ComponentFactory class.

This class extends XMLFilterImpl rather than DefaultHandler so that it can be used as a pass-through if appropriate.

Version:
0.01 29 August 2001
Author:
Simon St.Laurent

Field Summary
protected  CoreComponentI result
           
 
Fields inherited from class com.simonstl.moe.factory.SAXFactory
cqf, eventSource, listener, source, status, targetFile
 
Fields inherited from interface com.simonstl.moe.ComponentOutputI
CHUNKS, COLLECTING, FINISHED, NOTSTARTED, SAX
 
Constructor Summary
SAXFactoryTree(org.xml.sax.XMLReader parent)
           
 
Method Summary
 CoreComponentI getCurrentComponent()
          Not sure I'll keep this.
 boolean listen(CoreComponentI component)
          listen() takes components passed to it by component creators, returns true if there is a completion event.
 
Methods inherited from class com.simonstl.moe.factory.SAXFactory
characters, comment, endCDATA, endDTD, endElement, endEntity, endPrefixMapping, getEventSource, getSource, getStatus, ignorableWhitespace, main, printHelp, setEventSource, setListener, setReport, setSource, startCDATA, startDTD, startElement, startEntity, startEvents, startPrefixMapping, toString
 
Methods inherited from class org.xml.sax.helpers.XMLFilterImpl
endDocument, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, notationDecl, parse, parse, processingInstruction, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, setProperty, skippedEntity, startDocument, unparsedEntityDecl, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.simonstl.moe.ComponentOutputI
getStatus, setListener, setReport, startEvents
 

Field Detail

result

protected CoreComponentI result
Constructor Detail

SAXFactoryTree

public SAXFactoryTree(org.xml.sax.XMLReader parent)
Method Detail

listen

public boolean listen(CoreComponentI component)
               throws MOEException
Description copied from interface: ComponentInputI
listen() takes components passed to it by component creators, returns true if there is a completion event. (This can usually be ignored, except where components are the listeners.
Specified by:
listen in interface ComponentInputI

getCurrentComponent

public CoreComponentI getCurrentComponent()
Not sure I'll keep this.
Specified by:
getCurrentComponent in interface ComponentOutputI
Overrides:
getCurrentComponent in class SAXFactory