Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Accessing the workbench via servlets?
Accessing the workbench via servlets? [message #105252] Fri, 15 February 2008 12:28
Eclipse UserFriend
Originally posted by: stefan.melbinger.gmail.com

Hello everybody!

Following several tutorials, I managed to get a project running, which
consists of a bundle including a BundleActivator and some static and
dynamic (servlet) content. It's possible to access this content through a
browser, loading pages from localhost.

The aim of my experiments is to offer a webpage which allows the user to
click on links and thus make things happen within the running Eclipse
process. For example, I'd like a link called "open the JAR export wizard",
which, after clicking, opens the wizard within the Eclipse window.

The problem I encounter is that the servlet is of course not an UI-thread.
I cannot do the usual
IWorkbench workbench = PlatformUI.getWorkbench();
Shell shell = workbench.getActiveWorkbenchWindow().getShell();
because, as the API states, the getActiveWorkbenchWindow() function
returns "null if called from a non-UI thread".

I found out about the possibility of calling
Display.getDefault().[a]syncExec(). However, this is not working as
intended. Using asyncExec(), nothing happens at all, and using syncExec(),
the whole thing blocks forever.

Let me ask you, can my initial idea be realized in theory? Is it possible
to make things happen within Eclipse from clicking on a link in a browser,
thus running a GET request on a servlet, which is able to get a link to
the running process and, for example, open wizards or show cheatsheets?

Best regards,
Stefan Melbinger

Institute of Computer Technology
Technical University of Vienna
Previous Topic:Is config.ini necessary for a rcp app since version 3.3
Next Topic:Swing Mac - thread issue
Goto Forum:
  


Current Time: Thu Apr 25 21:13:43 GMT 2024

Powered by FUDForum. Page generated in 0.02591 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top