Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » e(fx)clipse » InjectionException at runtime of SWT/JavaFX product build with Maven
InjectionException at runtime of SWT/JavaFX product build with Maven [message #1139045] Tue, 15 October 2013 13:53 Go to next message
Mar Ifla is currently offline Mar IflaFriend
Messages: 22
Registered: September 2013
Junior Member
I implement a simple e4 SWT application with embedd JavaFX. It runs fine from within Eclipse and managed to build a product with Maven/Tycho.
But I get an error message (in log file) at runtime when I try to open an FX Part that injects BorderPane:
!MESSAGE Unable to create class 'my.app.parts.FXPart' from bundle '3'
!STACK 0
org.eclipse.e4.core.di.InjectionException: Unable to process "FXPart#createComposite()": no actual value was found for the argument "BorderPane".
So as far as I understood, the org.eclipse.fx.ui.di.interopt bundle is missing here. Is that correct?
How can I include it in my Maven build process?
I can't find a way to install it to my local Maven repo, as I get an error message about not finding javafx.* packages when I try to do a Maven install on the pom.xml in the o.e.f.u.d.interopt project from Github.

Re: InjectionException at runtime of SWT/JavaFX product build with Maven [message #1139066 is a reply to message #1139045] Tue, 15 October 2013 14:10 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5487
Registered: July 2009
Senior Member
Ok see, we are not building it nor do we publish it in any p2 repo. File
a bug and I'll try to get this done, until then I think the only
possible solution is to modify the pom.xml and include it to your own build.

Naturally you need to add it to your product or feature.

Tom

On 15.10.13 15:53, Mar Ifla wrote:
> I implement a simple e4 SWT application with embedd JavaFX. It runs fine
> from within Eclipse and managed to build a product with Maven/Tycho.
> But I get an error message (in log file) at runtime when I try to open
> an FX Part that injects BorderPane:
> !MESSAGE Unable to create class 'my.app.parts.FXPart' from bundle '3'
> !STACK 0
> org.eclipse.e4.core.di.InjectionException: Unable to process
> "FXPart#createComposite()": no actual value was found for the argument
> "BorderPane".So as far as I understood, the
> org.eclipse.fx.ui.di.interopt bundle is missing here. Is that correct?
> How can I include it in my Maven build process? I can't find a way to
> install it to my local Maven repo, as I get an error message about not
> finding javafx.* packages when I try to do a Maven install on the
> pom.xml in the o.e.f.u.d.interopt project from Github.
>
>
Re: InjectionException at runtime of SWT/JavaFX product build with Maven [message #1139176 is a reply to message #1139066] Tue, 15 October 2013 15:40 Go to previous messageGo to next message
Mar Ifla is currently offline Mar IflaFriend
Messages: 22
Registered: September 2013
Junior Member
Ok, thanks so far. Smile

I tried to install it to my local repo but getting an error message:
Missing requirement: org.eclipse.fx.ui.di.interopt 1.0.0.qualifier requires 'package javafx.embed.swing 2.2.0' but it could not be found

I'm quite new to Maven, so I have no idea how to solve this... Sad
Re: InjectionException at runtime of SWT/JavaFX product build with Maven [message #1139182 is a reply to message #1139176] Tue, 15 October 2013 15:45 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5487
Registered: July 2009
Senior Member
Well this means your build misses "org.eclipse.fx.javafx" as well.

To sum up you need:
* org.eclipse.fx.javafx
* org.eclipse.fx.osgi
* org.eclipse.fx.ui.di.interopt

To make all and everone happy. What p2-repos do you have configured in
your root pom.xml?

Tom

On 15.10.13 17:40, Mar Ifla wrote:
> Ok, thanks so far. :)
>
> I tried to install it to my local repo but getting an error message:
> Missing requirement: org.eclipse.fx.ui.di.interopt 1.0.0.qualifier
> requires 'package javafx.embed.swing 2.2.0' but it could not be found
> I'm quite new to Maven, so I have no idea how to solve this... :(
Re: InjectionException at runtime of SWT/JavaFX product build with Maven [message #1139205 is a reply to message #1139182] Tue, 15 October 2013 16:05 Go to previous message
Mar Ifla is currently offline Mar IflaFriend
Messages: 22
Registered: September 2013
Junior Member
To clarify this, I got the above error message when I tried to do a Maven install of org.eclipse.fx.ui.di.interopt alone without integrating it to my products build process.

I now managed to do a Maven install on the interopt artifact by adding the http://download.eclipse.org/efxclipse/runtime-nightly/site repository to its pom. It installs fine and I could add the plugin to my products features. The products Maven build runs and everything works at runtime.

I'm happy for the moment, thanks a lot. Smile
Previous Topic:OSGi: loading an FXML file from another bundle
Next Topic:Cannot add an item to the toolbar programmatically
Goto Forum:
  


Current Time: Sat Dec 20 14:36:20 GMT 2014

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

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