|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.wiley.posa3.pooling.ConnectionAdapter
A ConnectionAdapter class is used for legacy code integration, where it may not be possible to have the resource implement the Resource interface. The ConnectionAdapter class implements the Resource interface and then wraps the actual resource. The context information is also maintained by the ConnectionAdapter class.
| Constructor Summary | |
ConnectionAdapter(Connection connection)
Constuctor. |
|
ConnectionAdapter(Connection connection,
Identity id)
Constuctor. |
|
| Method Summary | |
Connection |
getConnection()
Get the connection object |
Identity |
getId()
Get the identity of this resource |
void |
method1()
Some generic method. |
void |
method2()
Some generic method. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ConnectionAdapter(Connection connection)
connection - the connection object that we are
adapting/wrapping.
public ConnectionAdapter(Connection connection,
Identity id)
connection - the connection object that we are
adapting/wrapping.id - a unique identifier for this connection.| Method Detail |
public Identity getId()
getId in interface Resourcepublic Connection getConnection()
public void method1()
method1 in interface Resourcepublic void method2()
method2 in interface Resource
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||