Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » Eclipse e4 application feasibility
Eclipse e4 application feasibility [message #1022069] Thu, 21 March 2013 08:30 Go to next message
ALex W is currently offline ALex WFriend
Messages: 56
Registered: July 2012
Member
Hello,

I'm thinking about designing an application using Eclipse E4. I was wondering if Eclipse e4 is a good choice (it seems to me) :

The application will be configurable to electronical devices. Only one at a time. To make it simple, there is one controller interface, and several possible controller implementation. I would like to offer the possibility to the user to switch the implementation (including or not the aplpication restart...). Is that possible and how ?

I've already done some tests and I plan to use Eclipse E4 with OSGI Declarative services. Right now I would like to be able to chose at runtime (from my application code), what component/bundle will be started at application launch.

One main point is the flexibility. Users will be allowed to develop plugin and install them in the application.

Thanks

Re: Eclipse e4 application feasibility [message #1022078 is a reply to message #1022069] Thu, 21 March 2013 08:45 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 423
Registered: July 2009
Senior Member
Hi Alex,

Sounds totally feasible.

Best regards,

Wim


> Hello,
>
> I'm thinking about designing an application using Eclipse E4. I was
wondering if Eclipse e4 is a good choice (it seems to me) :
>
> The application will be configurable to electronical devices. Only one at a
time. To make it simple, there is one controller interface, and several
possible controller implementation. I would like to offer the possibility to
the user to switch the implementation (including or not the aplpication
restart...). Is that possible and how ?
>
> I've already done some tests and I plan to use Eclipse E4 with OSGI
Declarative services. Right now I would like to be able to chose at runtime
(from my application code), what component/bundle will be started at
application launch.
>
> One main point is the flexibility. Users will be allowed to develop plugin
and install them in the application.
>
> Thanks
Re: Eclipse e4 application feasibility [message #1022111 is a reply to message #1022078] Thu, 21 March 2013 09:43 Go to previous messageGo to next message
Eclipse UserFriend
E4 is a really good friend of OSGi's declarative services.
Re: Eclipse e4 application feasibility [message #1022118 is a reply to message #1022111] Thu, 21 March 2013 09:56 Go to previous messageGo to next message
ALex W is currently offline ALex WFriend
Messages: 56
Registered: July 2012
Member
Thanks for the replies.
I'm currently looking online, but I can't find any mechanism to specify at runtime, which plugins should be started. Any clues ?

I guess it could be done by reading a configuration file registering every plugins ID and the use their activator to start it ? Or call a method inside the plugin if the lazy-activation is enabled ? Then OSGI DS would be automatically registered.
Re: Re: Eclipse e4 application feasibility [message #1022202 is a reply to message #1022118] Thu, 21 March 2013 13:28 Go to previous messageGo to next message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 423
Registered: July 2009
Senior Member
You can use DS and specify that a service can only start if a specific
required service is available.

So in your control code you can register a service which triggers the
activation of the real service.

e.g. what we do: If the user is logged in, we erect a LoginService which
triggers the activation of other services. If we take the LoginService down
then the dependent service shut down too.

I have a DS example on my github.

https://github.com/wimjongman/dynamic-services-demo


> Thanks for the replies.
> I'm currently looking online, but I can't find any mechanism to specify at
runtime, which plugins should be started. Any clues ?
>
> I guess it could be done by reading a configuration file registering every
plugins ID and the use their activator to start it ? Or call a method inside
the plugin if the lazy-activation is enabled ? Then OSGI DS would be
automatically registered.
Re: Re: Eclipse e4 application feasibility [message #1022268 is a reply to message #1022202] Thu, 21 March 2013 15:21 Go to previous message
Wim Jongman is currently offline Wim JongmanFriend
Messages: 423
Registered: July 2009
Senior Member
To run the code just create a new osgi run configuration, include the 5
projects and equinox ds then add required plugins and specify

-Dosgi.console.enable.builtin=true

to get the good old osgi console back

a gui will popup

look in the console and start and stop the store and user bundles. You will
see that the gui changes. To keep it on top go to the control class and
specify SWT.ON_TOP

It is a bit shitty but enough to understand the service dynamics


> You can use DS and specify that a service can only start if a specific
> required service is available.
>
> So in your control code you can register a service which triggers the
> activation of the real service.
>
> e.g. what we do: If the user is logged in, we erect a LoginService which
> triggers the activation of other services. If we take the LoginService down
> then the dependent service shut down too.
>
> I have a DS example on my github.
>
> https://github.com/wimjongman/dynamic-services-demo
>
>
>> Thanks for the replies.
>> I'm currently looking online, but I can't find any mechanism to specify at
> runtime, which plugins should be started. Any clues ?
>>
>> I guess it could be done by reading a configuration file registering every
> plugins ID and the use their activator to start it ? Or call a method
inside
> the plugin if the lazy-activation is enabled ? Then OSGI DS would be
> automatically registered.
Previous Topic:How are menus / toolbars related to a perspective
Next Topic:Perspective switch broken in Kepler M6
Goto Forum:
  


Current Time: Thu Apr 25 08:05:34 GMT 2024

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

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

Back to the top