SolarMetric Kodo JDO 2.5.0 Reverse Schema Tool

com.solarmetric.rd.kodo.meta
Class JDOMetaDataParser

java.lang.Object
  |
  +--org.xml.sax.helpers.DefaultHandler
        |
        +--com.solarmetric.rd.meta.XMLMetaDataParser
              |
              +--com.solarmetric.rd.meta.CFMetaDataParser
                    |
                    +--com.solarmetric.rd.kodo.meta.JDOMetaDataParser
All Implemented Interfaces:
org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler, MetaDataParser

public class JDOMetaDataParser
extends CFMetaDataParser

Custom SAX parser used by the system to quickly parse JDO metadata files.


Constructor Summary
JDOMetaDataParser(com.solarmetric.rd.kodo.conf.JDOConfiguration conf)
          Constructor.
 
Method Summary
protected  void endClass(java.lang.String className)
          Override this method marking the end of a declared <class>.
protected  void endClassElement(java.lang.String name)
          Override this method marking the end of an element within a declared <class>.
protected  void endExtension()
           
protected  void endField()
           
protected  void finish()
          Override this method to finish up after a parse; this is only called if no errors are encountered during parsing.
protected  java.io.Reader getDocType()
          Override this method to return any DOCTYPE declaration that should be dynamically included in xml documents that will be validated.
protected  java.lang.String getExtension()
          Override this method to return the extension used for metadata resources.
 java.lang.ClassLoader getPMClassLoader()
          Return the persistence manager class loader to pass on to parsed metadata instances.
 com.solarmetric.rd.kodo.meta.JDOMetaDataRepository getRepository()
          Returns the repository for this parser.
protected  void reset()
          Override this method to clear any state and ready the parser for a new document.
 void setPMClassLoader(java.lang.ClassLoader loader)
          Set the persistence manager class loader to pass on to parsed metadata instances.
 void setRepository(com.solarmetric.rd.kodo.meta.JDOMetaDataRepository repos)
          Set the metadata repository for this parser.
protected  void startArray(org.xml.sax.Attributes attrs)
           
protected  void startClass(java.lang.String className, org.xml.sax.Attributes attrs)
          Override this method marking the start of a declared <class>.
protected  void startClassElement(java.lang.String name, org.xml.sax.Attributes attrs)
          Override this method marking the start of an element within a declared <class>.
protected  void startCollection(org.xml.sax.Attributes attrs)
           
protected  void startExtension(org.xml.sax.Attributes attrs)
           
protected  void startField(org.xml.sax.Attributes attrs)
           
protected  void startMap(org.xml.sax.Attributes attrs)
           
 
Methods inherited from class com.solarmetric.rd.meta.CFMetaDataParser
classForName, endElement, getDeclaredClass, getDeclaredPackage, startElement
 
Methods inherited from class com.solarmetric.rd.meta.XMLMetaDataParser
addResult, characters, clear, currentClassLoader, endElement, error, fatalError, findMetaData, getClassLoader, getCurrentLocation, getLocation, getLog, getResults, getSourceFile, getSourceName, getText, isValidating, parse, parse, parse, parse, setClassLoader, setDocumentLocator, setLocation, setLog, setValidating, startElement, throwException, throwException
 
Methods inherited from class org.xml.sax.helpers.DefaultHandler
endDocument, endPrefixMapping, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, 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

JDOMetaDataParser

public JDOMetaDataParser(com.solarmetric.rd.kodo.conf.JDOConfiguration conf)
Constructor. Supply configuration.

Method Detail

getRepository

public com.solarmetric.rd.kodo.meta.JDOMetaDataRepository getRepository()
Returns the repository for this parser. If none has been set, creates a new repository and sets it.


setRepository

public void setRepository(com.solarmetric.rd.kodo.meta.JDOMetaDataRepository repos)
Set the metadata repository for this parser.


getPMClassLoader

public java.lang.ClassLoader getPMClassLoader()
Return the persistence manager class loader to pass on to parsed metadata instances.


setPMClassLoader

public void setPMClassLoader(java.lang.ClassLoader loader)
Set the persistence manager class loader to pass on to parsed metadata instances.


finish

protected void finish()
Description copied from class: XMLMetaDataParser
Override this method to finish up after a parse; this is only called if no errors are encountered during parsing. Subclasses should call super.finish () to resolve superclass state.

Overrides:
finish in class XMLMetaDataParser

getExtension

protected java.lang.String getExtension()
Description copied from class: XMLMetaDataParser
Override this method to return the extension used for metadata resources.

Specified by:
getExtension in class XMLMetaDataParser

reset

protected void reset()
Description copied from class: CFMetaDataParser
Override this method to clear any state and ready the parser for a new document. Subclasses should call super.reset () to clear superclass state.

Overrides:
reset in class CFMetaDataParser

getDocType

protected java.io.Reader getDocType()
                             throws java.io.IOException
Description copied from class: XMLMetaDataParser
Override this method to return any DOCTYPE declaration that should be dynamically included in xml documents that will be validated. Returns null by default.

Overrides:
getDocType in class XMLMetaDataParser
java.io.IOException

startClass

protected void startClass(java.lang.String className,
                          org.xml.sax.Attributes attrs)
                   throws org.xml.sax.SAXException
Description copied from class: CFMetaDataParser
Override this method marking the start of a declared <class>. The given class name will not include the package.

Specified by:
startClass in class CFMetaDataParser
org.xml.sax.SAXException

endClass

protected void endClass(java.lang.String className)
Description copied from class: CFMetaDataParser
Override this method marking the end of a declared <class>. The given class name will not include the package.

Specified by:
endClass in class CFMetaDataParser

startClassElement

protected void startClassElement(java.lang.String name,
                                 org.xml.sax.Attributes attrs)
                          throws org.xml.sax.SAXException
Description copied from class: CFMetaDataParser
Override this method marking the start of an element within a declared <class>.

Specified by:
startClassElement in class CFMetaDataParser
org.xml.sax.SAXException

endClassElement

protected void endClassElement(java.lang.String name)
                        throws org.xml.sax.SAXException
Description copied from class: CFMetaDataParser
Override this method marking the end of an element within a declared <class>.

Specified by:
endClassElement in class CFMetaDataParser
org.xml.sax.SAXException

startField

protected void startField(org.xml.sax.Attributes attrs)
                   throws org.xml.sax.SAXException
org.xml.sax.SAXException

endField

protected void endField()

startArray

protected void startArray(org.xml.sax.Attributes attrs)
                   throws org.xml.sax.SAXException
org.xml.sax.SAXException

startCollection

protected void startCollection(org.xml.sax.Attributes attrs)
                        throws org.xml.sax.SAXException
org.xml.sax.SAXException

startMap

protected void startMap(org.xml.sax.Attributes attrs)
                 throws org.xml.sax.SAXException
org.xml.sax.SAXException

startExtension

protected void startExtension(org.xml.sax.Attributes attrs)

endExtension

protected void endExtension()

SolarMetric Kodo JDO 2.5.0 Reverse Schema Tool

Copyright 2001,2002,2003 SolarMetric, Inc. All Rights Reserved.