com.infoengine.connector
Class IeConnectionFactory

java.lang.Object
  extended bycom.infoengine.connector.IeConnectionFactory
All Implemented Interfaces:
javax.resource.cci.ConnectionFactory, Referenceable, javax.resource.Referenceable, Serializable

public class IeConnectionFactory
extends Object
implements javax.resource.cci.ConnectionFactory

CCI connection factory used to create connections to the underlying EIS (Info*Engine).
Also used to get instances of RecordFactory and ResourceAdapterMetaData
This object is referenceable and so can be stored in an LDAP directory for use by applications in a "non-managed" scenario. The AdminTool supplied can be used to bind and unbind references to this object in the LDAP directory.

See Also:
Serialized Form

Field Summary
private  IeConnectionRequestInfo cxInfo
           
private  javax.resource.spi.ConnectionManager cxManager
           
private  Log log
           
private  IeManagedConnectionFactory managedCxFactory
           
private  boolean managedScenario
           
private  Reference reference
           
 
Constructor Summary
  IeConnectionFactory()
          used when object reconstructed from JNDI lookup
gets a default ManagedConnectionFactory and ConnectionManager instance
(package private) IeConnectionFactory(IeManagedConnectionFactory factory, javax.resource.spi.ConnectionManager manager, IeConnectionRequestInfo rqInfo, Log l)
          constructor used in a managed scenario
in this case the ConnectionManager is provided by the j2ee container (application server)
 
Method Summary
 javax.resource.cci.Connection getConnection()
          get a new CCI Connection
 javax.resource.cci.Connection getConnection(javax.resource.cci.ConnectionSpec properties)
          get a new CCI Connection using specific properties
 javax.resource.cci.ResourceAdapterMetaData getMetaData()
          get metadata about this resource adapter
 javax.resource.cci.RecordFactory getRecordFactory()
          get an instance of the default RecordFactory
 Reference getReference()
          build a JNDI reference that reflects this IeConnectionFactory's properties
 void setLogLevel(int level)
          In an unmanaged scenario there is no way to condition LogLevel.
 void setReference(Reference reference)
          configure this IeConnection factory based on JNDI stored properties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cxInfo

private IeConnectionRequestInfo cxInfo

cxManager

private javax.resource.spi.ConnectionManager cxManager

managedCxFactory

private IeManagedConnectionFactory managedCxFactory

reference

private Reference reference

managedScenario

private boolean managedScenario

log

private Log log
Constructor Detail

IeConnectionFactory

public IeConnectionFactory()
used when object reconstructed from JNDI lookup
gets a default ManagedConnectionFactory and ConnectionManager instance

See Also:
IeManagedConnectionFactory, IeConnectionManager

IeConnectionFactory

IeConnectionFactory(IeManagedConnectionFactory factory,
                    javax.resource.spi.ConnectionManager manager,
                    IeConnectionRequestInfo rqInfo,
                    Log l)
              throws javax.resource.ResourceException
constructor used in a managed scenario
in this case the ConnectionManager is provided by the j2ee container (application server)

Parameters:
factory - the IeManagedConnectionFactory
manager - the ConnectionManager (from the app server)
rqInfo - the connection request info object
l - Log
Throws:
javax.resource.ResourceException
See Also:
IeManagedConnectionFactory, IeConnectionRequestInfo
Method Detail

getConnection

public javax.resource.cci.Connection getConnection()
                                            throws javax.resource.ResourceException
get a new CCI Connection

Specified by:
getConnection in interface javax.resource.cci.ConnectionFactory
Returns:
Connection a new connection
Throws:
javax.resource.ResourceException

getConnection

public javax.resource.cci.Connection getConnection(javax.resource.cci.ConnectionSpec properties)
                                            throws javax.resource.ResourceException
get a new CCI Connection using specific properties

Specified by:
getConnection in interface javax.resource.cci.ConnectionFactory
Parameters:
properties - connection properties
Returns:
Connection
Throws:
javax.resource.ResourceException
See Also:
IeConnectionSpec

getMetaData

public javax.resource.cci.ResourceAdapterMetaData getMetaData()
                                                       throws javax.resource.ResourceException
get metadata about this resource adapter

Specified by:
getMetaData in interface javax.resource.cci.ConnectionFactory
Returns:
ResourceAdapterMetaData
Throws:
javax.resource.ResourceException

getRecordFactory

public javax.resource.cci.RecordFactory getRecordFactory()
                                                  throws javax.resource.ResourceException
get an instance of the default RecordFactory

Specified by:
getRecordFactory in interface javax.resource.cci.ConnectionFactory
Returns:
RecordFactory
Throws:
javax.resource.ResourceException
See Also:
IeRecordFactory

setReference

public void setReference(Reference reference)
configure this IeConnection factory based on JNDI stored properties

Specified by:
setReference in interface javax.resource.Referenceable
Parameters:
reference - the JNDI reference

getReference

public Reference getReference()
build a JNDI reference that reflects this IeConnectionFactory's properties

Specified by:
getReference in interface Referenceable
Returns:
the JNDI reference

setLogLevel

public void setLogLevel(int level)
In an unmanaged scenario there is no way to condition LogLevel. Convenience method that lets clients set the LogLevel.

Parameters:
level -