Book a Demo

Author Topic: using Java to access eap  (Read 3808 times)

ag108

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
using Java to access eap
« on: July 29, 2014, 06:20:56 am »
Hi, I'm brand new to Sparx EA and have been trying to get the java examples to work. I'd like to have a Java program access an eap we built. I set up eclipse and tried accessing a repository using
    org.sparx.Repository r = new org.sparx.Repository();
and got:
Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\Windows\System32\SSJavaCOM.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform
I also tried to use the ExampleUI and got:
   java.net.MalformedURLException
I wasn't sure how to set the URL. Here's what I tried:
urlString = "file:///C:/Program Files (x86)/Sparx Systems/EA/Code Samples/Java_Sample/src/org/sparx/javaexample/examples";

Sorry for all the nitty gritty. If there's some simple way to gain access, I'd greatly appreciate any pointers.
    Thank you,
    ag

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: using Java to access eap
« Reply #1 on: July 29, 2014, 06:40:49 am »
I'm no Java guy, but the error message suggests that you have the wrong Java (32 bit) running on your 64 bit machine (what the heck? it should be able to do that?!).

q.

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: using Java to access eap
« Reply #2 on: July 29, 2014, 09:01:22 am »
The Java interface has the same restriction as anything else connecting to EA. Only 32 bit processes can communicate effectively with EA being a 32 bit process. The error sounds like you are running a 64 bit JVM.
« Last Edit: July 29, 2014, 09:01:49 am by simonm »

ag108

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: using Java to access eap
« Reply #3 on: July 29, 2014, 10:15:17 pm »
Thank you both. I am running a 64 bit JVM. Time to load in the 32 bit Java.