com.metamatrix.platform.config.spi.xml
Class XMLCurrentConfigurationReader

java.lang.Object
  extended by com.metamatrix.platform.config.spi.xml.XMLCurrentConfigurationReader
All Implemented Interfaces:
CurrentConfigurationReader

public class XMLCurrentConfigurationReader
extends java.lang.Object
implements CurrentConfigurationReader


Field Summary
static java.lang.String INSTALL_DATE
          The date of installation of the MetaMatrix suite
 
Constructor Summary
XMLCurrentConfigurationReader()
           
 
Method Summary
 void close()
          This method should close the connection to the repository that holds the current configuration.
 void connect(java.util.Properties env)
          This method should connect to the repository that holds the current configuration, using the specified properties.
 ConfigurationModelContainer getConfigurationModel()
          Obtain the next startup configuration model.
 java.util.Properties getConfigurationProperties()
          Obtain the properties for the current configuration.
protected  XMLConfigurationReader getConfigurationReader()
           
protected  XMLConfigurationWriter getConfigurationWriter()
           
 Configuration getNextStartupConfiguration()
          Obtain the next startup configuration.
protected  ConfigUserTransaction getWriteTransaction()
           
 void indicateSystemShutdown()
           
 void performSystemInitialization(boolean forceInitialization)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTALL_DATE

public static final java.lang.String INSTALL_DATE
The date of installation of the MetaMatrix suite

See Also:
Constant Field Values
Constructor Detail

XMLCurrentConfigurationReader

public XMLCurrentConfigurationReader()
Method Detail

connect

public void connect(java.util.Properties env)
             throws ConfigurationConnectionException
This method should connect to the repository that holds the current configuration, using the specified properties. The implementation may not use logging but instead should rely upon returning an exception in the case of any errors.

Specified by:
connect in interface CurrentConfigurationReader
Parameters:
env - the environment properties that define the information
Throws:
ConfigurationConnectionException - if there is an error establishing the connection.

close

public void close()
           throws java.lang.Exception
This method should close the connection to the repository that holds the current configuration. The implementation may not use logging but instead should rely upon returning an exception in the case of any errors.

Specified by:
close in interface CurrentConfigurationReader
Throws:
java.lang.Exception - if there is an error establishing the connection.

getConfigurationProperties

public java.util.Properties getConfigurationProperties()
                                                throws ConfigurationException
Obtain the properties for the current configuration. The implementation may not use logging but instead should rely upon returning an exception in the case of any errors.

Returns:
the properties
Throws:
ConfigurationException - if an error occurred within or during communication with the repository.

getNextStartupConfiguration

public Configuration getNextStartupConfiguration()
                                          throws ConfigurationException
Obtain the next startup configuration. The implementation may not use logging but instead should rely upon returning an exception in the case of any errors.

Returns:
the serializable Configuration instance
Throws:
ConfigurationException - if an error occurred within or during communication with the repository.

getConfigurationModel

public ConfigurationModelContainer getConfigurationModel()
                                                  throws ConfigurationException
Obtain the next startup configuration model. The implementation may not use logging but instead should rely upon returning an exception in the case of any errors.

Specified by:
getConfigurationModel in interface CurrentConfigurationReader
Returns:
the serializable Configuration instance
Throws:
ConfigurationException - if an error occurred within or during communication with the repository.

performSystemInitialization

public void performSystemInitialization(boolean forceInitialization)
                                 throws StartupStateException,
                                        ConfigurationException
Specified by:
performSystemInitialization in interface CurrentConfigurationReader
Throws:
StartupStateException
ConfigurationException

indicateSystemShutdown

public void indicateSystemShutdown()
                            throws ConfigurationException
Specified by:
indicateSystemShutdown in interface CurrentConfigurationReader
Throws:
ConfigurationException
See Also:
CurrentConfigurationInitializer

getWriteTransaction

protected ConfigUserTransaction getWriteTransaction()
                                             throws ConfigTransactionException,
                                                    ConfigurationException
Throws:
ConfigTransactionException
ConfigurationException

getConfigurationReader

protected XMLConfigurationReader getConfigurationReader()

getConfigurationWriter

protected XMLConfigurationWriter getConfigurationWriter()


Copyright © 2009. All Rights Reserved.