Download
FAQ History |
API
Search Feedback |
Common Client Interface
This section describes how components use the Connector architecture Common Client Interface (CCI) API and a resource adapter to access data from an EIS.
Defined by the J2EE Connector architecture specification, the CCI defines a set of interfaces and classes whose methods allow a client to perform typical data access operations. The CCI interfaces and classes are as follows:
ConnectionFactory
: Provides an application component with aConnection
instance to an EIS.Connection
: Represents the connection to the underlying EIS.ConnectionSpec
: Provides a means for an application component to pass connection-request-specific properties to theConnectionFactory
when making a connection request.Interaction
: Provides a means for an application component to execute EIS functions, such as database stored procedures.InteractionSpec
: Holds properties pertaining to an application component's interaction with an EIS.Record
: The superclass for the various kinds of record instances. Record instances can beMappedRecord
,IndexedRecord
, orResultSet
instances, all of which inherit from theRecord
interface.RecordFactory
: Provides an application component with aRecord
instance.IndexedRecord
: Represents an ordered collection ofRecord
instances based on thejava.util.List
interface.A client or application component that uses the CCI to interact with an underlying EIS does so in a prescribed manner. The component must establish a connection to the EIS's resource manager, and it does so using the
ConnectionFactory
. TheConnection
object represents the actual connection to the EIS and is used for subsequent interactions with the EIS.The component performs its interactions with the EIS, such as accessing data from a specific table, using an
Interaction
object. The application component defines theInteraction
object using anInteractionSpec
object. When the application component reads data from the EIS (such as from database tables) or writes to those tables, it does so using a particular type ofRecord
instance: either aMappedRecord
, anIndexedRecord
, or aResultSet
instance. Just as theConnectionFactory
createsConnection
instances, aRecordFactory
createsRecord
instances.Note, too, that a client application that relies on a CCI resource adapter is very much like any other J2EE client that uses enterprise bean methods.
Download
FAQ History |
API
Search Feedback |
All of the material in The J2EE(TM) 1.4 Tutorial is copyright-protected and may not be published in other works without express written permission from Sun Microsystems.