com.facetmap.sql
Class ConnectionManager.Basic

java.lang.Object
  extended by com.facetmap.sql.ConnectionManager.Basic
All Implemented Interfaces:
ConnectionManager
Enclosing interface:
ConnectionManager

public static class ConnectionManager.Basic
extends java.lang.Object
implements ConnectionManager

This implementation performs a primitive JDBC handling of the Connection lifecycle, taking its JDBC parameters from the Properties passed in at construction.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.facetmap.sql.ConnectionManager
ConnectionManager.Basic, ConnectionManager.DataSourceWrapper
 
Constructor Summary
ConnectionManager.Basic(java.util.Properties props)
          Construct a basic ConnectionManager.
 
Method Summary
 java.sql.Connection getConnection()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConnectionManager.Basic

public ConnectionManager.Basic(java.util.Properties props)
                        throws DataException,
                               InternalException
Construct a basic ConnectionManager. Required properties are:
  • com.facetmap.sql.jdbcDriver - fully-qualified name of the driver class
  • com.facetmap.sql.jdbcUrl - JDBC-protocol URL of the database to use, for example jdbc:mysql://localhost:3306/databaseName?user=facetmap
  • Throws:
    DataException
    InternalException
    Method Detail

    getConnection

    public java.sql.Connection getConnection()
                                      throws java.sql.SQLException
    Specified by:
    getConnection in interface ConnectionManager
    Throws:
    java.sql.SQLException