站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 4.0.1 sp1 j2ee API Documentation 英文版文档

PooledConnection (JBoss J2EE API) - JBoss 4.0.1 sp1 j2ee API Documentation 英文版文档


javax.sql
Interface PooledConnection

All Known Subinterfaces:
XAConnection

public interface PooledConnection

A PooledConnection object is a connection object that provides hooks for connection pool management. A PooledConnection object represents a physical connection to a data source.


Method Summary
 void addConnectionEventListener(ConnectionEventListener connectionEventListener)
          Add an event listener.
 void close()
          Close the physical connection.
 Connection getConnection()
          Create an object handle for this physical connection.
 void removeConnectionEventListener(ConnectionEventListener connectionEventListener)
          Remove an event listener.
 

Method Detail

addConnectionEventListener

public void addConnectionEventListener(ConnectionEventListener connectionEventListener)
Add an event listener.

Parameters:
connectionEventListener - - The listener

close

public void close()
           throws SQLException
Close the physical connection.

Throws:
SQLException - - if a database-access error occurs.

getConnection

public Connection getConnection()
                         throws SQLException
Create an object handle for this physical connection. The object returned is a temporary handle used by application code to refer to a physical connection that is being pooled.

Returns:
a Connection object
Throws:
SQLException - - if a database-access error occurs.

removeConnectionEventListener

public void removeConnectionEventListener(ConnectionEventListener connectionEventListener)
Remove an event listener.

Parameters:
connectionEventListener - - The listener


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.