Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.huihoo.jfox.pool.connection
Class SimplePoolableConnection

    java.lang.Object
      |
      +--org.huihoo.jfox.pool.connection.SimplePoolableConnection

All Implemented Interfaces:
  PoolableConnection, PoolableObject

public class SimplePoolableConnection
extends java.lang.Object
implements PoolableConnection

wrap a physical connection and make it can put into pool

Author:
  Kelvin Wu

Constructor Summary
`SimplePoolableConnection(java.sql.Connection conn)`

Method Summary
`void` | `activate()` actvite the object before it be retrived
`void` | `close()`
`java.sql.Connection` | `getConnection()` get the physical connection
`ObjectPool` | `getPool()` Get the pool that this poolableConnection belongs to, so the poolableConnection can be managed by the pool.
`boolean` | `isUsing()`
`void` | `passivate()` passivate the object before it be restored, set the status to initialized
`void` | `reallyClose()` Close the physical connection that this PoolableConnection wrapped.
`void` | `setPool(ObjectPool pool)` Set which pool that this PoolableConnection belongs to.
`void` | `setUsing(boolean b)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### SimplePoolableConnection

    public SimplePoolableConnection(java.sql.Connection conn)

Method Detail

### getPool

    public ObjectPool getPool()

  Description copied from interface: `PoolableConnection`
  Get the pool that this poolableConnection belongs to, so the poolableConnection can be managed by the pool.
  Specified by:
    `getPool` in interface `PoolableConnection`

### setPool

    public void setPool(ObjectPool pool)

  Description copied from interface: `PoolableConnection`
  Set which pool that this PoolableConnection belongs to.
  Specified by:
    `setPool` in interface `PoolableConnection`
  Following copied from interface: `org.huihoo.jfox.pool.connection.PoolableConnection`
  Parameters:
    `pool` -

### reallyClose

    public void reallyClose()

  Description copied from interface: `PoolableConnection`
  Close the physical connection that this PoolableConnection wrapped.
  Specified by:
    `reallyClose` in interface `PoolableConnection`

### activate

    public void activate()
                  throws java.lang.Exception

  Description copied from interface: `PoolableObject`
  actvite the object before it be retrived
  Specified by:
    `activate` in interface `PoolableObject`

### passivate

    public void passivate()
                   throws java.lang.Exception

  Description copied from interface: `PoolableObject`
  passivate the object before it be restored, set the status to initialized
  Specified by:
    `passivate` in interface `PoolableObject`

### setUsing

    public void setUsing(boolean b)

  Specified by:
    `setUsing` in interface `PoolableConnection`

### isUsing

    public boolean isUsing()

  Specified by:
    `isUsing` in interface `PoolableConnection`

### getConnection

    public java.sql.Connection getConnection()

  Description copied from interface: `PoolableConnection`
  get the physical connection
  Specified by:
    `getConnection` in interface `PoolableConnection`
  Following copied from interface: `org.huihoo.jfox.pool.connection.PoolableConnection`
  Returns:

### close

    public void close()

  Specified by:
    `close` in interface `PoolableConnection`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD