Java object gateway


I’m having a few problems with the Java object gateway.

Firstly the examples in the documentation does not work as the property names are incorrect and even when corrected I still can’t get an Integer class to instantiate (I think this is due to the constructor expecting an int). I have however been able to instantiate a String and get the value.

I would like to know where I must put my jar file with my java classes? I’ve tried putting it everywhere but Mediator can’t find them. The class path property does not make a diff either.


I’m using Mediator 7.3 and Tomcat 5

I have another question on Java Object Gateway. May I know how to translate the following java statement into Java Object Gateway?


Or, in general, how do I call a static method using Java Object Gateway? I tried the following but it gives me error. (I know java.lang,Runtime is not an object, but I have no clue on how to call a static method.)


Hi Jean,

I usually put the jars I need in the component factory’s classpath. Administration Console → Component Factory → configuration → general.
Click on Modify Factory Config. Put your jars in the text field labeled External Jar URLS.
Example: file:c:/efa724/fresno/jars/baseutil.jar;file:c:/efa724/fresno/externalJars/OROMatcher2.jar;

Click on the Modify button. Then stop and start the component factory.

If you are using jars that use native libraries (example: MQ classes for Java) then you need to put the jars in the system classpath.