Automate eap to xmi export in Enterprise Architect - command-line

Is there a way to automate the export (conversion) from *.eap to *.xmi in Enterprise Architect? Ideally something like
ea -eap file.eap -xmi file.xmi
We want to use automated Continuous Integration and clicking through GUI dialogs is not an option. For complex reasons we do not want to check in the xmi in our VCS after the eap file was modified.
The FAQ for XMI export at http://www.sparxsystems.com/enterprise_architect_user_guide/8.0/projects_and_teams/exporttoxmi.html sadly does not describe an automated way.

See How to automate the generation of HTML output in Enterprise Architect

Related

Auto import XML files in Sparx Enterprise Architect repository

I would like to auto import XML files that contains information about changed packages, diagrams, elements, and so on to my repository on a MySQL server.
There is a functionality in the EA, located in "Import/Export" -> "Import package from XMI file". Is there any way to trigger that function from a script or from a program to automate that?
Yes, check the operation ImportPackageXMI in the Project Interface. You can use that operation from an add-in, external program or EA script.

UML - Is an installer an artifact?

I'm making a deployment diagram in UML for a windows application software. I wanted to know if an installer is an artifact and how should I draw the diagram exactly?
Do I only put the installer inside the node that represents a client machine, or I put not only the installer, but the components that it installs in association with installer?
Artifacts physically represent your components. A component is a logically consistent part of your application.
So you have an artifact for your installer only if it is a part of your project. I mean if you designed your own installer, then it is an artifact because it is a part of the "result" of your software project. Yet even in this case it may not be very useful to have it appear in a deployment diagram, because you typically do not deploy an installer...
Otherwise it will not be an artifact. You will have artifacts for your installed components, not the installer itself.
In UML terms your installer file is an artifact. Now whether you should or not show it in a diagram, it depends. A basic tenet of architecture documentation is that you should only produce architecture diagrams if there's anyone who'll benefit from it.
If the stakeholder of that diagram is someone who will install the software, then it may make sense to have the installer in the diagram.
If the stakeholder of the diagram is someone who will simply try to configure or fix issues on the installed application, then you'd probably better show the installed artifacts.
In any case, the proper way to show that an artifact is deployed to a node is using the <<deploy>>stereotyped dependency. Example (from UML 2.5 specs, Fig. 19.3):

How can I export an eclipse feature for multiple platforms?

I have an eclipse feature with a few platform dependent fragments (jogamp based plugins, to be precise)
I'd like to export that feature using PDE export. It works, as usual, only it will omit all plugins that do not match my current platform.
I want to use this exported feature as a p2 site that can be used from different platforms, so that's no good.
Is there a way to export an eclipse feature for all platforms?
Thanks, Frank
There's no easy way to get all the platforms from within eclipse as a PDE export. I took a crack at using PDE build as a workspace export, http://pweclipse.blogspot.com/2011/02/pde-build-as-workspace-export.html but it requires some digging to get all the properties correct and it's specific to one workspace.
It's better to set up a proper headless PDE build to generate your p2 site.

Alfresco - Using APIs in a new project

I wanted to know if a new project in eclipse we could import the jar Alfresco and used for example by creating just a jsp with a field of research that would seek a metadata ..?
Thank you.
I think you got it wrong. Alfresco is not library you import to your project. Alfresco is a complete Enterprise Content Management system. For more information visit http://wiki.alfresco.com/wiki/Main_Page
But I wish it was that simple.
I think this way to do it:
Install alfresco from scratch... as standalone project.
Then develop a webscript using the Alfresco Web Script API, that allows you to create a restful service. Your web script can preform lucene queries to search metadata.
Create your jsp form.
Then you can use Ajax to get data from your restful service.

Automation in Eclipse

I am using Eclipse and have a few simple tasks(such as uploading files to a server) I would like to automate. Where should I be looking, is something like ANT applicable here?
Any pointers appreciated.
You can use the external tools of eclipse (see eclipse help).
As stated in "FAQ How do I add my own external tools?":
External tools are applications or scripts that typically act as extensions to your development environment. For example, they may be used to execute scripts to package and deploy your application or to run an external compiler on your source files.
External tools allow an end user to achieve a basic level of integration for a non-Eclipse-aware tool without writing a plug-in.
External tools are created and configured via Run > External Tools > External Tools or from the drop-down menu on the Run button with the toolbox overlay.
That way, your script (.bat, ant, maven, whatever you want) can be run with a simple click on the external tools menu.
You can indeed associate an external tool to ant, since:
The Ant UI as provided in Eclipse comes with a first-class Ant build-file editor, including syntax highlighting, Content Assist, templates, and content formatting.
This editor is automatically associated with files named build.xml and can be associated with other file names from the Workbench > File Associations preference page.
The Ant UI also has a wizard for running Ant scripts and a toolbar button for repeating previous builds.
(source: eclipse.org)
Maven is another solution. There are many mojos (custom plugins) for existing tasks that are highly configurable, or if you get stuck you can write your own.
The trade off is the setup and learning curve can be fairly steep, so I guess it boils down to what you need it for, if you'll reuse it, etc, etc.
Eclipse Monkey is an atempt to make Eclipse scriptable to automate tedious tasks.