Interface UnWrapper
-
- All Known Implementing Classes:
DBCPUnWrapper
,LifecycleConnectionUnWrapper
public interface UnWrapper
GenericConnection
unwrapper. A user can test if the unwrapper is able to unwrap a certain connection, on positive answer he can callunwrap(Connection)
to get the native connection- Author:
- Andrea Aime - TOPP
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
canUnwrap(Connection conn)
Returns true if this unwrapper knows how to unwrap the specified connectionboolean
canUnwrap(Statement st)
Returns tru if this unwrapper knows how to unwrap the specified statementConnection
unwrap(Connection conn)
Returns the unwrapped connection, of throwsIllegalArgumentException
if the passedConnection
is not supported (canUnwrap(Connection)
returns false}.Statement
unwrap(Statement statement)
Returns the unwrapped statement, of throwsIllegalArgumentException
if the passedStatement
is not supported (canUnwrap(Statement)
returns false}.
-
-
-
Method Detail
-
canUnwrap
boolean canUnwrap(Connection conn)
Returns true if this unwrapper knows how to unwrap the specified connection
-
canUnwrap
boolean canUnwrap(Statement st)
Returns tru if this unwrapper knows how to unwrap the specified statement
-
unwrap
Connection unwrap(Connection conn)
Returns the unwrapped connection, of throwsIllegalArgumentException
if the passedConnection
is not supported (canUnwrap(Connection)
returns false}.
-
unwrap
Statement unwrap(Statement statement)
Returns the unwrapped statement, of throwsIllegalArgumentException
if the passedStatement
is not supported (canUnwrap(Statement)
returns false}.
-
-