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

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


javax.resource.cci
Interface ConnectionFactory

All Superinterfaces:
Referenceable, Referenceable, Serializable

public interface ConnectionFactory
extends Serializable, Referenceable

The ConnectionFactory provides an interface for getting a Connection from the Resource adapter. The application retrieves a reference to the ConnectionFactory through a JNDI lookup. ConnectionFactory extends java.io.Serializable and javax.resource.Referenceable in order to support JNDI lookup.


Method Summary
 Connection getConnection()
          Gets a connection from the resource adapter.
 Connection getConnection(ConnectionSpec properties)
          Gets a connection from the resource adapter.
 ResourceAdapterMetaData getMetaData()
          Gets metadata for the resource adapter.
 RecordFactory getRecordFactory()
          Gets a RecordFactory instance for use in creating Record objects.
 
Methods inherited from interface javax.resource.Referenceable
setReference
 
Methods inherited from interface javax.naming.Referenceable
getReference
 

Method Detail

getConnection

public Connection getConnection()
                         throws ResourceException
Gets a connection from the resource adapter. When using this method the client does not pass any security information, and wants the container to manage sign-on. This is called container managed sign-on.

Throws:
ResourceException

getConnection

public Connection getConnection(ConnectionSpec properties)
                         throws ResourceException
Gets a connection from the resource adapter. When using this method the client passes in the security information. This is called component managed sign-on.

Throws:
ResourceException

getRecordFactory

public RecordFactory getRecordFactory()
                               throws ResourceException
Gets a RecordFactory instance for use in creating Record objects.

Throws:
ResourceException

getMetaData

public ResourceAdapterMetaData getMetaData()
                                    throws ResourceException
Gets metadata for the resource adapter. This call does not require an active connection.

Throws:
ResourceException


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