com.infoengine.connector
Class IeConnection

java.lang.Object
  extended bycom.infoengine.connector.IeConnection
All Implemented Interfaces:
javax.resource.cci.Connection

public class IeConnection
extends Object
implements javax.resource.cci.Connection

CCI connection to Info*Engine
A CCI connection represents a handle to a connection and not a physical connection. Calling the close method does not close the underlying physical connection but allows an application server to mark the connection as available and return it to a connection pool.


Field Summary
private  boolean closed
           
private  Log log
           
private  IeManagedConnection managedCx
           
private  IeCCILocalTransaction transaction
           
 
Constructor Summary
(package private) IeConnection(IeManagedConnection managed, Log l)
          create a connection handle associated with a ManagedConnection
 
Method Summary
 void close()
          close this connection handle
closing a handle doesn't actually close the physical connection to the EIS it simply allows marks a connection as available allowing an application server to return the connection to a connection pool.
 javax.resource.cci.Interaction createInteraction()
          create an interaction from this connection that can be used to invoke business methods on the underlying EIS.
(package private)  IeManagedConnection getIeManagedConnection()
          get the managed connection this handle is associated with
 javax.resource.cci.LocalTransaction getLocalTransaction()
          get a LocalTransaction instance that an application can use to manually demarcate a transaction.
 javax.resource.cci.ConnectionMetaData getMetaData()
          get the metadata associated with this connection
(package private)  PhysicalConnection getPhysicalConnection()
          get the physical connection object this handle is associated with
 javax.resource.cci.ResultSetInfo getResultSetInfo()
          results sets are not supported.
(package private)  void setIeManagedConnection(IeManagedConnection managed)
          associate this connection handle with another managed connection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

managedCx

private IeManagedConnection managedCx

transaction

private IeCCILocalTransaction transaction

closed

private boolean closed

log

private Log log
Constructor Detail

IeConnection

IeConnection(IeManagedConnection managed,
             Log l)
       throws javax.resource.ResourceException
create a connection handle associated with a ManagedConnection

Parameters:
managed - the managed connection
l - Log
Method Detail

setIeManagedConnection

void setIeManagedConnection(IeManagedConnection managed)
associate this connection handle with another managed connection

Parameters:
managed - the new managed connection

getIeManagedConnection

IeManagedConnection getIeManagedConnection()
get the managed connection this handle is associated with

Returns:
IeManagedConnection

close

public void close()
           throws javax.resource.ResourceException
close this connection handle
closing a handle doesn't actually close the physical connection to the EIS it simply allows marks a connection as available allowing an application server to return the connection to a connection pool.

Specified by:
close in interface javax.resource.cci.Connection
Throws:
javax.resource.ResourceException

createInteraction

public javax.resource.cci.Interaction createInteraction()
                                                 throws javax.resource.ResourceException
create an interaction from this connection that can be used to invoke business methods on the underlying EIS.

Specified by:
createInteraction in interface javax.resource.cci.Connection
Returns:
Interaction
Throws:
javax.resource.ResourceException
IllegalStateException - if this handle is closed

getLocalTransaction

public javax.resource.cci.LocalTransaction getLocalTransaction()
                                                        throws javax.resource.ResourceException
get a LocalTransaction instance that an application can use to manually demarcate a transaction.

Specified by:
getLocalTransaction in interface javax.resource.cci.Connection
Returns:
LocalTransaction
Throws:
javax.resource.ResourceException
IllegalStateException - if this handle is closed

getPhysicalConnection

PhysicalConnection getPhysicalConnection()
get the physical connection object this handle is associated with

Returns:
PhysicalConnection
Throws:
IllegalStateException - if this handle is closed

getMetaData

public javax.resource.cci.ConnectionMetaData getMetaData()
                                                  throws javax.resource.ResourceException
get the metadata associated with this connection

Specified by:
getMetaData in interface javax.resource.cci.Connection
Returns:
ConnectionMetaData
Throws:
javax.resource.ResourceException
IllegalStateException - if this handle is closed

getResultSetInfo

public javax.resource.cci.ResultSetInfo getResultSetInfo()
                                                  throws javax.resource.ResourceException
results sets are not supported. calling this method always causes a NotSupportedException to be thrown

Specified by:
getResultSetInfo in interface javax.resource.cci.Connection
Throws:
javax.resource.ResourceException
NotSupportedException - always