Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

safejdbc
Class DataSourceAdapter  view DataSourceAdapter download DataSourceAdapter.java

java.lang.Object
  extended bysafejdbc.DataSourceAdapter
All Implemented Interfaces:
ConnectionProvider
Direct Known Subclasses:
TxDataSourceAdapter

public class DataSourceAdapter
extends java.lang.Object
implements ConnectionProvider

This class is a Adapter for DataSources to provide the ConnectionProvider interface. It is especially usefull in an J2EE Enviornment.


Field Summary
private  javax.sql.DataSource _datasource
           
 
Constructor Summary
DataSourceAdapter(javax.sql.DataSource datasource)
           
 
Method Summary
 java.sql.Connection getConnection()
          This method is called to actually give the connection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_datasource

private javax.sql.DataSource _datasource
Constructor Detail

DataSourceAdapter

public DataSourceAdapter(javax.sql.DataSource datasource)
Method Detail

getConnection

public java.sql.Connection getConnection()
                                  throws java.sql.SQLException
Description copied from interface: ConnectionProvider
This method is called to actually give the connection

Specified by:
getConnection in interface ConnectionProvider