org.apache.torque.generator.configuration.source
Class JdbcMetadataSourceSaxHandler

java.lang.Object
  extended by org.xml.sax.helpers.DefaultHandler
      extended by org.apache.torque.generator.configuration.source.SourceSaxHandler
          extended by org.apache.torque.generator.configuration.source.JdbcMetadataSourceSaxHandler
All Implemented Interfaces:
ContentHandler, DTDHandler, EntityResolver, ErrorHandler

public class JdbcMetadataSourceSaxHandler
extends SourceSaxHandler

Reads jdbc metadata source definitions from the controller configuration file.


Constructor Summary
JdbcMetadataSourceSaxHandler(ConfigurationProvider configurationProvider, ProjectPaths projectPaths, ConfigurationHandlers configurationHandlers)
          Constructor.
 
Method Summary
 void endElement(String uri, String localName, String rawName)
          
 SourceProvider getSourceProvider()
          Returns the configuration filled with the contents of the parsed snippet.
 void startElement(String uri, String localName, String rawName, Attributes attributes)
          
 
Methods inherited from class org.apache.torque.generator.configuration.source.SourceSaxHandler
characters, finished, getConfigurationHandlers, getConfigurationProvider, getProjectPaths, getSourceProcessConfiguration, isFinished
 
Methods inherited from class org.xml.sax.helpers.DefaultHandler
endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JdbcMetadataSourceSaxHandler

public JdbcMetadataSourceSaxHandler(ConfigurationProvider configurationProvider,
                                    ProjectPaths projectPaths,
                                    ConfigurationHandlers configurationHandlers)
Constructor.

Parameters:
configurationProvider - The access object for the configuration files, not null.
projectPaths - The paths of the surrounding project, not null.
configurationHandlers - All known configuration handlers, not null.
Throws:
NullPointerException - if an argument is null.
Method Detail

startElement

public void startElement(String uri,
                         String localName,
                         String rawName,
                         Attributes attributes)
                  throws SAXException

Specified by:
startElement in interface ContentHandler
Overrides:
startElement in class SourceSaxHandler
Throws:
SAXException

endElement

public void endElement(String uri,
                       String localName,
                       String rawName)
                throws SAXException

Specified by:
endElement in interface ContentHandler
Overrides:
endElement in class SourceSaxHandler
Throws:
SAXException

getSourceProvider

public SourceProvider getSourceProvider()
Returns the configuration filled with the contents of the parsed snippet.

Specified by:
getSourceProvider in class SourceSaxHandler
Returns:
the configuration which was filled, not null if a matching snippet was processed.


Copyright © 2000-2012 The Apache Software Foundation. All Rights Reserved.