Expresso 5-6

com.jcorporate.expresso.core.db
Class DBConfig

java.lang.Object
  extended bycom.jcorporate.expresso.kernel.EmbeddedComponent
      extended bycom.jcorporate.expresso.core.db.DBConfig
All Implemented Interfaces:
ComponentLifecycle, ExpressoComponent, Serializable

public class DBConfig
extends EmbeddedComponent
implements ComponentLifecycle

Database Configuration Component

Author:
Michael Rimov
See Also:
Serialized Form

Constructor Summary
DBConfig()
          Default constructor.
 
Method Summary
 void configure(Configuration newConfig)
          Configuration Event.
 void destroy()
          Destroy method.
 List getAllConfigurations()
          Retrieves a list of all JDBCConfig objects.
 com.jcorporate.expresso.core.db.config.JDBCConfig getCurrentConfig()
          Retrieves the current Configuration
 String getMetadataName()
          Retrieve the name of the metadata that is embedded in the parent component.
 List getSupportedConfigurations()
          Retrieves a list of all supported configuration keys and types as retrieved from the metadata for this component.
 void initialize()
          Initialize Lifecycle Event
 void reconfigure(Configuration newConfig)
          ReconfigurationEvent In this implementation there is no actual configuration parameters, but we get our configuration info from the parent.
 
Methods inherited from class com.jcorporate.expresso.kernel.EmbeddedComponent
getMetaData, getParent, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DBConfig

public DBConfig()
Default constructor.

Method Detail

getMetadataName

public String getMetadataName()
Retrieve the name of the metadata that is embedded in the parent component.

Specified by:
getMetadataName in class EmbeddedComponent
Returns:
java.lang.String

initialize

public void initialize()
Initialize Lifecycle Event

Specified by:
initialize in interface ComponentLifecycle

configure

public void configure(Configuration newConfig)
               throws ConfigurationException
Configuration Event. In this implementation there is no actual configuration parameters, but we get our configuration info from the parent.

Specified by:
configure in interface ComponentLifecycle
Parameters:
newConfig - the new configuration bean.
Throws:
ConfigurationException - upon configuration error (such as bad nesting, for example)

reconfigure

public void reconfigure(Configuration newConfig)
                 throws ConfigurationException
ReconfigurationEvent In this implementation there is no actual configuration parameters, but we get our configuration info from the parent.

Specified by:
reconfigure in interface ComponentLifecycle
Parameters:
newConfig - the new configuration bean.
Throws:
ConfigurationException - upon configuration error (such as bad nesting, for example)

destroy

public void destroy()
Destroy method.

Specified by:
destroy in interface ComponentLifecycle

getSupportedConfigurations

public List getSupportedConfigurations()
Retrieves a list of all supported configuration keys and types as retrieved from the metadata for this component.

Returns:
java.util.List of ValidValue objects

getAllConfigurations

public List getAllConfigurations()
Retrieves a list of all JDBCConfig objects.

Returns:
java.util.List of JDBCConfig objects

getCurrentConfig

public com.jcorporate.expresso.core.db.config.JDBCConfig getCurrentConfig()
Retrieves the current Configuration

Returns:
JDBCConfig object

Expresso 5-6

Please see www.jcorporate.com for information about new Expresso releases.