Package org.hawaiiframework.sql
Class DataSourceProxyFactory
- java.lang.Object
-
- org.hawaiiframework.sql.DataSourceProxyFactory
-
public class DataSourceProxyFactory extends Object
Factory to create a datasource proxy with listeners.
-
-
Constructor Summary
Constructors Constructor Description DataSourceProxyFactory(List<OrderedQueryExecutionListener> listeners)
The constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataSource
proxy(DataSource target)
Creates a data source proxy for thetarget
iff there are listeners.
-
-
-
Constructor Detail
-
DataSourceProxyFactory
public DataSourceProxyFactory(List<OrderedQueryExecutionListener> listeners)
The constructor.- Parameters:
listeners
- The listeners to use in the data source proxy.
-
-
Method Detail
-
proxy
public DataSource proxy(DataSource target)
Creates a data source proxy for thetarget
iff there are listeners. Otherwise it will return the target itself.- Parameters:
target
- The data source to create a proxy for.- Returns:
- The data source to use.
-
-