You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Antoine Mischler <an...@dooapp.com> on 2010/05/25 13:50:45 UTC

[Taspetry IoC] Using Tapestry IoC with JavaFX

Hi guys,

I've been working happily with Tapestry IoC in the past, and now I'm trying
to use it with JavaFX. Actually, annotations are not supported in JavaFX but
I thought it should be possible to use it by building the registry manually
and getting the services explicitly. So I wrote something like that:

var builder: RegistryBuilder = new RegistryBuilder();
builder.add(InjectionTestModule.class);
var registry: Registry = builder.build();
registry.performRegistryStartup();
registry.getService(TestInterface.class).test();

where InjectionTestModule is a javafx class containing a build method
responsible for the instantiation of TestInterface (also a javafx class).
However when I run this example the following exception is thrown:

java.lang.RuntimeException: Module class
injectiontest.services.InjectionTestModule contains unrecognized public
methods: public boolean
com.sun.javafx.runtime.FXBase.getAsBoolean$(int,int), public boolean
com.sun.javafx.runtime.FXBase.update$(com.sun.javafx.runtime.FXObject,int,int,int,int,int),
public boolean com.sun.javafx.runtime.FXBase.varTestBits$(int,int,int),
public byte...

followed by a bunch of unrecognized methods. I think these methods are
automatically generated by the javafx compiler.
So my question is: is there a way to make the registry less sensible to
unrecognized methods?
This would be great to be able to use Tapestry IoC with JavaFX, and I hope a
workaround is possible.

Thanks for any advice.
Cheers,
-- 
Antoine Mischler
www.dooapp.com
+33 (0)6 50 90 72 94

Re: Re: [Taspetry IoC] Using Tapestry IoC with JavaFX

Posted by Antoine Mischler <an...@dooapp.com>.
The link to the corresponding JIRA entry:
https://issues.apache.org/jira/browse/TAP5-1171 (which I created by cloning
the groovy issue, sorry about that, apparently it was not the best way to do
it, but it should be correctly filled now)

Antoine

On Wed, May 26, 2010 at 2:28 PM, Antoine Mischler <an...@dooapp.com>wrote:

> Hi,
>
> Thanks for your answers. I tried with Taspestry 5.2.0 but I still get the
> problem. After some investigations it looks like that the unrecognized
> methods are not synthetic. Actually, every JavaFX object extends the
> com.sun.javafx.runtime.FXBase class bringing those unrecognized methods. So
> the problem is slightly different than for Groovy. I'll create a JIRA about
> this.
>
> Cheers,
> Antoine
>
> On Wed, May 26, 2010 at 9:22 AM, Kristian Marinkovic <
> kristian.marinkovic@porsche.co.at> wrote:
>
>> hi,
>>
>> there was a issue that already has been fixed:
>> https://issues.apache.org/jira/browse/TAP5-839
>>
>> g,
>> kris
>>
>>
>>
>> Von:    "Thiago H. de Paula Figueiredo" <th...@gmail.com>
>> An:     "Tapestry users" <us...@tapestry.apache.org>
>> Datum:  25.05.2010 15:06
>> Betreff:        Re: [Taspetry IoC] Using Tapestry IoC with JavaFX
>>
>>
>>
>> On Tue, 25 May 2010 08:50:45 -0300, Antoine Mischler <an...@dooapp.com>
>> wrote:
>>
>> > Hi guys,
>>
>> Hi!
>>
>> > followed by a bunch of unrecognized methods. I think these methods are
>> > automatically generated by the javafx compiler.
>> > So my question is: is there a way to make the registry less sensible to
>> > unrecognized methods?
>>
>> There was the same problem with writing module classes in Scala or Groovy,
>>
>> I don't remember exactly. This was already addressed in Tapestry-IoC with
>> some explicit checks. Post a JIRA about it so the committers can take a
>> look at it. Please include a sample project to speed up the process.
>>
>> --
>> Thiago H. de Paula Figueiredo
>> Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
>> and instructor
>> Owner, Ars Machina Tecnologia da Informação Ltda.
>> http://www.arsmachina.com.br
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>>
>
>
> --
> Antoine Mischler
> www.dooapp.com
> +33 (0)6 50 90 72 94
>



-- 
Antoine Mischler
www.dooapp.com
+33 (0)6 50 90 72 94

Re: Re: [Taspetry IoC] Using Tapestry IoC with JavaFX

Posted by Antoine Mischler <an...@dooapp.com>.
Hi,

Thanks for your answers. I tried with Taspestry 5.2.0 but I still get the
problem. After some investigations it looks like that the unrecognized
methods are not synthetic. Actually, every JavaFX object extends the
com.sun.javafx.runtime.FXBase class bringing those unrecognized methods. So
the problem is slightly different than for Groovy. I'll create a JIRA about
this.

Cheers,
Antoine

On Wed, May 26, 2010 at 9:22 AM, Kristian Marinkovic <
kristian.marinkovic@porsche.co.at> wrote:

> hi,
>
> there was a issue that already has been fixed:
> https://issues.apache.org/jira/browse/TAP5-839
>
> g,
> kris
>
>
>
> Von:    "Thiago H. de Paula Figueiredo" <th...@gmail.com>
> An:     "Tapestry users" <us...@tapestry.apache.org>
> Datum:  25.05.2010 15:06
> Betreff:        Re: [Taspetry IoC] Using Tapestry IoC with JavaFX
>
>
>
> On Tue, 25 May 2010 08:50:45 -0300, Antoine Mischler <an...@dooapp.com>
> wrote:
>
> > Hi guys,
>
> Hi!
>
> > followed by a bunch of unrecognized methods. I think these methods are
> > automatically generated by the javafx compiler.
> > So my question is: is there a way to make the registry less sensible to
> > unrecognized methods?
>
> There was the same problem with writing module classes in Scala or Groovy,
>
> I don't remember exactly. This was already addressed in Tapestry-IoC with
> some explicit checks. Post a JIRA about it so the committers can take a
> look at it. Please include a sample project to speed up the process.
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
> and instructor
> Owner, Ars Machina Tecnologia da Informação Ltda.
> http://www.arsmachina.com.br
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
>


-- 
Antoine Mischler
www.dooapp.com
+33 (0)6 50 90 72 94

Antwort: Re: [Taspetry IoC] Using Tapestry IoC with JavaFX

Posted by Kristian Marinkovic <kr...@porsche.co.at>.
hi, 

there was a issue that already has been fixed:
https://issues.apache.org/jira/browse/TAP5-839

g,
kris



Von:    "Thiago H. de Paula Figueiredo" <th...@gmail.com>
An:     "Tapestry users" <us...@tapestry.apache.org>
Datum:  25.05.2010 15:06
Betreff:        Re: [Taspetry IoC] Using Tapestry IoC with JavaFX



On Tue, 25 May 2010 08:50:45 -0300, Antoine Mischler <an...@dooapp.com> 
wrote:

> Hi guys,

Hi!

> followed by a bunch of unrecognized methods. I think these methods are
> automatically generated by the javafx compiler.
> So my question is: is there a way to make the registry less sensible to
> unrecognized methods?

There was the same problem with writing module classes in Scala or Groovy, 
 
I don't remember exactly. This was already addressed in Tapestry-IoC with 
some explicit checks. Post a JIRA about it so the committers can take a 
look at it. Please include a sample project to speed up the process.

-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, 
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org



Re: [Taspetry IoC] Using Tapestry IoC with JavaFX

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Tue, 25 May 2010 08:50:45 -0300, Antoine Mischler <an...@dooapp.com>  
wrote:

> Hi guys,

Hi!

> followed by a bunch of unrecognized methods. I think these methods are
> automatically generated by the javafx compiler.
> So my question is: is there a way to make the registry less sensible to
> unrecognized methods?

There was the same problem with writing module classes in Scala or Groovy,  
I don't remember exactly. This was already addressed in Tapestry-IoC with  
some explicit checks. Post a JIRA about it so the committers can take a  
look at it. Please include a sample project to speed up the process.

-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org