org.apache.shale.examples.sqlbrowser
Class InternalDataSource

java.lang.Object
  extended by org.apache.derby.jdbc.ReferenceableDataSource
      extended by org.apache.derby.jdbc.EmbeddedDataSource
          extended by org.apache.shale.examples.sqlbrowser.InternalDataSource
All Implemented Interfaces:
Serializable, Referenceable, ObjectFactory, DataSource

public class InternalDataSource
extends org.apache.derby.jdbc.EmbeddedDataSource

Trivial implementation of DataSource that wraps a data source provided by Derby, and provides a shutdown hook.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.apache.derby.jdbc.EmbeddedDataSource
driver
 
Constructor Summary
InternalDataSource(String url)
          Construct a connection pool for the specified URL.
 
Method Summary
 void shutdown()
          Cause the embedded Derby database to be shut down.
 
Methods inherited from class org.apache.derby.jdbc.EmbeddedDataSource
equals, getAttributesAsPassword, getConnection, getConnection, getConnectionAttributes, getCreateDatabase, getShutdownDatabase, setAttributesAsPassword, setConnectionAttributes, setCreateDatabase, setShutdownDatabase
 
Methods inherited from class org.apache.derby.jdbc.ReferenceableDataSource
getDatabaseName, getDataSourceName, getDescription, getLoginTimeout, getLogWriter, getObjectInstance, getPassword, getReference, getUser, setDatabaseName, setDataSourceName, setDescription, setLoginTimeout, setLogWriter, setPassword, setUser
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.sql.DataSource
getLoginTimeout, getLogWriter, setLoginTimeout, setLogWriter
 

Constructor Detail

InternalDataSource

public InternalDataSource(String url)
                   throws SQLException

Construct a connection pool for the specified URL.

Throws:
SQLException
Method Detail

shutdown

public void shutdown()
              throws SQLException

Cause the embedded Derby database to be shut down.

Throws:
SQLException


Copyright © 2004-2007 Apache Software Foundation. All Rights Reserved.