org.exolab.castor.jdo.engine
Class JDOConfLoader

java.lang.Object
  extended byorg.exolab.castor.jdo.engine.JDOConfLoader

public class JDOConfLoader
extends java.lang.Object

Helper class to load the Castor JDO configuration from its configuration file.

Author:
Werner Guttmann

Constructor Summary
JDOConfLoader()
           
 
Method Summary
static void deleteConfiguration()
          Deletes JDO configuration.
static Database getDatabase(java.lang.String databaseName, org.xml.sax.InputSource source, org.xml.sax.EntityResolver resolver)
           
static Database[] getDatabases(org.xml.sax.InputSource source, org.xml.sax.EntityResolver resolver)
           
static Database[] getDatabases(JdoConf jdoConf)
           
static Mapping[] getMapping(java.lang.String databaseName, org.xml.sax.InputSource source, org.xml.sax.EntityResolver resolver)
           
static TransactionDemarcation getTransactionDemarcation(org.xml.sax.InputSource source, org.xml.sax.EntityResolver resolver)
           
static boolean isLoaded()
          Indicates whether JDO configuration has loaded successfully.
static void loadConfiguration(org.xml.sax.InputSource source, org.xml.sax.EntityResolver resolver)
          Loads the JDO configuration from the specified InputSource.
static void loadConfiguration(JdoConf jdoConf)
          Loads the JDO configuration from the specified InputSource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDOConfLoader

public JDOConfLoader()
Method Detail

loadConfiguration

public static void loadConfiguration(org.xml.sax.InputSource source,
                                     org.xml.sax.EntityResolver resolver)
                              throws MappingException
Loads the JDO configuration from the specified InputSource.

Parameters:
source - An InputSource pointing to the JDO configuration to be loaded.
resolver - An EntityResolver instance.
Throws:
MappingException - If the JDO configuration cannot be loaded/unmarshalled.

loadConfiguration

public static void loadConfiguration(JdoConf jdoConf)
Loads the JDO configuration from the specified InputSource.

Parameters:
jdoConf - An JDoConf instance representing a JDO configuration to be loaded.

getDatabases

public static Database[] getDatabases(JdoConf jdoConf)

getDatabases

public static Database[] getDatabases(org.xml.sax.InputSource source,
                                      org.xml.sax.EntityResolver resolver)
                               throws MappingException
Throws:
MappingException

getDatabase

public static Database getDatabase(java.lang.String databaseName,
                                   org.xml.sax.InputSource source,
                                   org.xml.sax.EntityResolver resolver)
                            throws MappingException
Throws:
MappingException

getTransactionDemarcation

public static TransactionDemarcation getTransactionDemarcation(org.xml.sax.InputSource source,
                                                               org.xml.sax.EntityResolver resolver)
                                                        throws MappingException
Throws:
MappingException

getMapping

public static Mapping[] getMapping(java.lang.String databaseName,
                                   org.xml.sax.InputSource source,
                                   org.xml.sax.EntityResolver resolver)
                            throws MappingException
Throws:
MappingException

deleteConfiguration

public static void deleteConfiguration()
Deletes JDO configuration.


isLoaded

public static boolean isLoaded()
Indicates whether JDO configuration has loaded successfully.

Returns:
True if JDO configuration is loaded.


Intalio Inc. (C) 1999-2004. All rights reserved http://www.intalio.com