Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [emf-dev] FW: About Web Editors

Thanks a lot Ed!


From: <emf-dev-bounces@xxxxxxxxxxx> on behalf of Ed Merks <ed.merks@xxxxxxxxx>
Reply-To: Eclipse Modelling Framework <emf-dev@xxxxxxxxxxx>
Date: Wednesday, December 28, 2016 at 15:50
To: "emf-dev@xxxxxxxxxxx" <emf-dev@xxxxxxxxxxx>
Subject: Re: [emf-dev] FW: About Web Editors

Please use the forum to ask questions.

Make sure the FAQ doesn't already answer your question, e.g.,

To integrate with some other RESTful resource back-end, you could use a specialized URIHandlerImpl that you could add to your resource set's URI converter; you can look at the various existing subclasses for design ideas.

Please don't post follow-up questions on the mailing list but rather start a thread on the forum.

On 28.12.2016 14:39, Delchev, Nedelcho wrote:
Hi EMF Developers,

Can you please help with an idea how to handle the issue below?
In general can we initialise EMF from an abstract resource (not from the local file system)? Do you have some examples on how to do this?

Thanks in advance!


From: SAP SAP <nedelcho.delchev@xxxxxxx>
Date: Friday, November 25, 2016 at 17:14
To: Amine Lajmi <aminelajmi@xxxxxxxxx>
Cc: "Pavlov, Georgi" <georgi.pavlov@xxxxxxx>, "Pavlov, Yordan" <yordan.pavlov@xxxxxxx>, Dimitar Panayotov <dimitar.panayotov@xxxxxxx>, "Atanasov, Momchil" <momchil.atanasov@xxxxxxx>, Markus Knauer <mknauer@xxxxxxxxxxxxxxxxx>
Subject: Re: About Web Editors

Hi Amine,

Wow!!! It looks really veeery nice! :)

For the EMF in the past we hacked something which @Momchil probably can recall. The major problem is as you described that EMF relies on the file system directly instead of the Resource API. I hope that this has been changed meanwhile, but I am not sure.
In general in Eclipse Dirigible you can use either Resource API (hacked version by us) or Repository API (own implementation) to access resources. The Repository itself could be Local (file-system based), DB (RDBMS implementation), Git (read-only as of now), etc. The Resource API in Dirigible is connected as a layer on top of the Repository API, hence follow the same channel for accessing the actual resources. We have to see what have to be done in EMF to allow this. Once we make it, we can open Dirigible for the whole world of EMF based plugins available.

@Markus, do you know somebody from EMF team that can jump in and help here?

Btw. Just an idea – can we provide a custom protocol handler for the URIs that we can use? Similar thing we had in the integration of the Groovy engine:


From: Amine Lajmi <aminelajmi@xxxxxxxxx>
Date: Friday, November 25, 2016 at 14:00
To: SAP SAP <nedelcho.delchev@xxxxxxx>
Cc: "Pavlov, Georgi" <georgi.pavlov@xxxxxxx>, "Pavlov, Yordan" <yordan.pavlov@xxxxxxx>, Dimitar Panayotov <dimitar.panayotov@xxxxxxx>
Subject: Re: About Web Editors

Hi Nedelcho,

First attempt, looks nice right ? :-)

                              intégrées 1

I have however some issues with EMF integration: s there a way to access the local repository location ? I need it to be ble to create an URI as the EMF API needs to check if the file exists in the file system when the resource is created otherwise it throws an exception.

For now, I hacked it this way:

IFile file = ((SourceFileEditorInput) editorInput).getFile();
IWorkspace workspace = WorkspaceLocator.getWorkspace();
IWorkspaceRoot root = workspace.getRoot();
IPath locationRoot = root.getLocation();
String ROOT = "D:/dev/sap/eclipse/dirigible_local/root";
IPath total = new Path(ROOT).append(locationRoot).append(file.getFullPath());
URI x = URI.createFileURI(total.toString());
ResourceSet resourceSet = getDefaultResourceSet();
XtextResource result = (XtextResource) resourceSet.getResource(x, true);

Is there a better way to do it ?


emf-dev mailing list
To change your delivery options, retrieve your password, or unsubscribe from this list, visit

Back to the top