Author Topic: Add-in in Java?  (Read 4112 times)

AlanT

  • EA User
  • **
  • Posts: 66
  • Karma: +0/-0
    • View Profile
Add-in in Java?
« on: November 17, 2010, 02:12:26 pm »
I have not written an EA add-in before. . . . Can one be written in Java?

I see examples on the web site for C#, but not Java.

Thanks, Alan


Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13136
  • Karma: +547/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Add-in in Java?
« Reply #1 on: November 17, 2010, 05:10:51 pm »
Alan,

Yes you can.
See C:\Program Files\Sparx Systems\EA\Code Samples\Java_Sample
for an example.

Geert

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8038
  • Karma: +118/-20
    • View Profile
Re: Add-in in Java?
« Reply #2 on: November 18, 2010, 08:25:45 am »
No you can't.  You can use Java with the automation interface but it is not possible to use it for an add-in.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13136
  • Karma: +547/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Add-in in Java?
« Reply #3 on: November 18, 2010, 04:56:11 pm »
Oh, I didn't know that  :-[

Geert

AlanT

  • EA User
  • **
  • Posts: 66
  • Karma: +0/-0
    • View Profile
Re: Add-in in Java?
« Reply #4 on: November 19, 2010, 02:12:54 am »
Geert,
           I have requested that this be changed at http://www.sparxsystems.com/cgi-bin/yabb/YaBB.cgi?num=1290035070 (features).  You may want to express your support for this suggested change.

                  Alan

stao

  • EA User
  • **
  • Posts: 137
  • Karma: +0/-0
    • View Profile
Re: Add-in in Java?
« Reply #5 on: November 19, 2010, 03:58:13 am »
Quote
No you can't.  You can use Java with the automation interface but it is not possible to use it for an add-in.


sorry for the question but where is the difference?

stao

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8038
  • Karma: +118/-20
    • View Profile
Re: Add-in in Java?
« Reply #6 on: November 19, 2010, 08:35:12 am »
The short answer is that we have written code to allow Java to call the EA COM objects by wrapping them with Java objects and JNI calls.  (Actually, apart from a small amount of support code this was generated using EA Transformations and Code Generation.)

The code to allow EA to call into Java is completely separate and although I have my theories on how it can be done, it hasn't been done.