# Java object gateway

**URL:** <https://techcommunity.softwareag.com/t/java-object-gateway/58692>\
**Category:** Forum\
**Tags:** Former-Crossvision-Products, Service-Orchestrator\
**Created:** [December 17, 2004, 4:35pm UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692 "2004-12-17T16:35:39Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jean\_Bodemer](https://avatars.discourse-cdn.com/v4/letter/j/c67d28/32.png) [@Jean\_Bodemer](https://techcommunity.softwareag.com/u/Jean_Bodemer)\
**Post date:** [December 17, 2004, 4:35pm UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692/1 "2004-12-17T16:35:39Z")

</div>

Hi,  
  
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.  
  
Regards,  
Jean

---

<div class="post-metadata">

**Author:** ![Jean\_Bodemer](https://avatars.discourse-cdn.com/v4/letter/j/c67d28/32.png) [@Jean\_Bodemer](https://techcommunity.softwareag.com/u/Jean_Bodemer)\
**Post date:** [December 17, 2004, 4:37pm UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692/2 "2004-12-17T16:37:47Z")

</div>

I’m using Mediator 7.3 and Tomcat 5

---

<div class="post-metadata">

**Author:** ![Prince1](https://avatars.discourse-cdn.com/v4/letter/p/e480ec/32.png) [@Prince1](https://techcommunity.softwareag.com/u/Prince1)\
**Post date:** [December 19, 2004, 2:17pm UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692/3 "2004-12-19T14:17:43Z")

</div>

I have another question on Java Object Gateway. May I know how to translate the following java statement into Java Object Gateway?  
  
Runtime.getRuntime().exec(“dir”);  
  
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.)  
  
  
  
Thanks!

---

<div class="post-metadata">

**Author:** ![Jason](https://avatars.discourse-cdn.com/v4/letter/j/dc4da7/32.png) [@Jason](https://techcommunity.softwareag.com/u/Jason)\
**Post date:** [December 20, 2004, 5:15am UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692/4 "2004-12-20T05:15:36Z")

</div>

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.  
  
Jason

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 2:39pm UTC](https://techcommunity.softwareag.com/t/java-object-gateway/58692/5 "2021-04-02T14:39:24Z")

</div>


