If you instantiate a Connection
object for an Oracle9i
Release 1 database, then, by default, the Connection
object will
instantiate the Sun ORB (J2SE 1.3.1). If an ORB already exists within the application,
then, before you connect, you must set that ORB on BI Beans.
If you want to use an ORB that is different from the default ORB, then you must create the different ORB before you connect and set it on BI Beans. This ORB must be compatible with Borland® Enterprise Server VisiBroker® Edition, VisiBroker for Java, version 4.5.
Note: If you are connecting to an Oracle9i Release 2 database, then BI Beans does not require an ORB.
You can choose either of the following approaches to set an ORB on BI Beans:
Use the Connection bean API (the preferred approach)
After you instantiate the Connection object and before you call its
connect
method, you must set the ORB property as shown in the following
example. This example assumes that the variable _orb
is of type
org.omg.CORBA.ORB
and is an existing ORB.
//Establishing a connection and setting an ORB oracle.dss.connection.client.Connection conn = new oracle.dss.connection.client.Connection(); conn.setProperty (oracle.dss.connection.common.CB.ORB, _orb);
Before you call the connect
method of the Connection
object, you must set the ORB as shown in the following example. This example
assumes that the variable _orb
is of type org.omg.CORBA.ORB
and is an existing ORB.
//Specifying the ORB for the application oracle.dss.appmodule.common.ORBUtils.setORB (_orb);