IRfcConnection and Related Objects
Definition
An IRfcConnection object represents an R/3 connection.
Use
While you can handle a single connection with the
SessionManager object, if you wish to create and use multiple connections, you need to create an IRfcConnection object for each connection.Once you set up the appropriate IRfcConnection object(s) you can create and use IRfcModule objects and their parameters within the context of a particular connection.
To use IRfcModule and its parameters within a particular connection you specify the IRfcConnection object in methods that create objects that require a connection (for example, when creating the IRfcModule object).
Integration
The following diagram shows the classes and interfaces related to the IRfcConnection.
You create an IRfcConnection object with the IRfcConnectionFactory object.
You create an IRfcConnectionFactory object with the
FactoryManager object.When creating an IRfcConnection object, you provide two objects as parameters:
UserInfo and ConnectInfo are the same objects as used by the
SessionManager for managing a connection. They supply the user logon information and the parameters of the system to connect to.To create an additional connection with different user or system parameters you simply use a different IRfcConnection object, and set its UserInfo and the ConnectInfo objects with different properties.
From an established RFC connection, you can obtain the R/3 system information by calling getSystemInfo. The method returns a SystemInfo object, which contains a list of name-value items that describe the R/3 system properties.
The ConnectionEvent and ConnectionListener classes are for subscribing to connection open, close, or abort events. The implementation class of the IRfcConnection interface fires ConnectionEvents whenever an action is made on the connection. The subscriber of these events should implement the ConnectionListener interface.
See Also
See the Java RFC HTML Reference documentation for the details of each of the classes and interfaces.