Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: P on June 10, 2009, 08:35:49 pm
-
Hi everybody!
I'm using Eclipse and Enterprise Architect 7.1 library (eaapi.jar). I must use the Java api to update the EA model, such as create a new class diagram, add a new class, attributes and so on.
All samples that I find are in Visual Basic 6.0 or C#...nothing java samples!!
Please help me! I would need at least a full documentation about the API of this library!
Thanks very much!
-
You can find some basic installation instructions here:
http://www.sparxsystems.com/uml_tool_guide/sdk_for_enterprise_architect/setup.html
I've not been able to find "real" Java examples, but if you look at
http://www.sparxsystems.com/uml_tool_guide/sdk_for_enterprise_architect/codeexamples.html and keep in mind that for any Object.attribute in VB there should be the corresponding getters and setters in Java, you should be able to start.
-
You'll find a Java sample in your EA install directory (at least with EA 7.5).
The documentation for the interface is available at http://www.sparxsystems.com/uml_tool_guide/sdk_for_enterprise_architect/theautomationinterface.html
As you've said, use getters and setters for the attributes though. (Same as you would need to do for C++.)
-
Hi P,
As Simon mentioned, there is a Java sample shipped with version 7.5 If you don't have version 7.5 or don't plan to upgrade, please feel free to send an email to [email protected] marked for my attention and we'll send a copy back to you in reply.
-
Thank you very much for all support. I will sent mail to request for Java API and sample code. :D
-
I have sent mail to [email protected]. But nothing happen. I haven't got any response back. It's very hard for me to coding without API. Even I can learn from VB example, but there are many thing I have to guess. I have to doubt that what's this parameter used for from example.
For example,
t = method.Parameters.AddNew("TestParam","string")
I don't know that what the second parameter ("string") is used for. :(
-
I sent a reply to your email at about midday yesterday. Try checking your spam filters etc to see if it hasn't got caught up there.
-
Hi,
Sorry, Michael. No any mails from sparxsystems (even in Spam folder). You might send to the wrong email. My email is [email protected]. Could you please try again?
Thank you,
P.