|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.openjpa.lib.jdbc.DelegatingDataSource
org.apache.openjpa.lib.jdbc.DecoratingDataSource
public class DecoratingDataSource
Delegating data source that maintains a list of ConnectionDecorator
s.
Constructor Summary | |
---|---|
DecoratingDataSource(javax.sql.DataSource ds)
Constructor. |
Method Summary | |
---|---|
void |
addDecorator(ConnectionDecorator decorator)
Add a connection decorator. |
void |
addDecorators(java.util.Collection decorators)
Add multiple connection decorators efficiently. |
void |
clearDecorators()
Clear all decorators. |
java.sql.Connection |
getConnection()
|
java.sql.Connection |
getConnection(java.lang.String user,
java.lang.String pass)
|
java.util.Collection |
getDecorators()
Return a read-only list of connection decorators in the order they were added. |
boolean |
removeDecorator(ConnectionDecorator decorator)
Remove a connection decorator. |
Methods inherited from class org.apache.openjpa.lib.jdbc.DelegatingDataSource |
---|
appendInfo, close, equals, getDelegate, getInnermostDelegate, getLoginTimeout, getLogWriter, hashCode, setLoginTimeout, setLogWriter, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DecoratingDataSource(javax.sql.DataSource ds)
Method Detail |
---|
public java.util.Collection getDecorators()
public void addDecorator(ConnectionDecorator decorator)
public void addDecorators(java.util.Collection decorators)
public boolean removeDecorator(ConnectionDecorator decorator)
public void clearDecorators()
public java.sql.Connection getConnection() throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
getConnection
in class DelegatingDataSource
java.sql.SQLException
public java.sql.Connection getConnection(java.lang.String user, java.lang.String pass) throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
getConnection
in class DelegatingDataSource
java.sql.SQLException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |