Running Programs that Use JDK 1.2 and Java RFC
JDK 1.2 CORBA Class Compatibility with JRFC
JDK 1.2 provides an implementation for org.omg.CORBA classes. These class files are not compatible with the Java RFC Class Library.
Using -Xbootclasspath to Override the Default CORBA Classes Used
If you are using the JDK 1.2 classes with Java RFC, you need to use the java -Xbootclasspath option to override the Java JDK 1.2 classes with the classes of the desired middleware.
For example, to specify using the Orbix implementation of the org.omg.CORBA classes (which is compatible with the Java RFC and is also provided with the Java RFC kit), you must issue the following command when running your Java program:
java
- Xbootclasspath:< JRFC - install - directory>\client\classes;<classpaths - list> <Java - class - file - name>Where
:JRFC-install-directory |
directory where the Java RFC Class Library is installed |
classpaths-list |
semicolon separated list of paths to all other classes you need to use |
Java-class-file-name |
name of your Java program class file containing main |
Example
Assume that the Java RFC program is installed in c:\sap\JRFC and JDK 1.2.1 is installed in c:\. To run a program called RfcClientMain, issue the following command at the console:
java
- Xbootclasspath:c:\sap\JRFC\client\classes;c:\jdk1.2.1\jre\lib\rt.jar apps\RfcClientMainDeploying Your Program to an End User
When deploying a program that uses the JDK 1.2 and the Java RFC Class Library, you may need to provide your users with a batch file containing the above command for setting the CORBA classes.
The batch files for running the
sample programs delivered with the Java RFC kit contain a similar commands for setting up the reference to the class files.