Thursday, February 26, 2015

Re: JSO: Why does this fail?

OK, I understood (which actually I find scary).
Thanks!

2015-02-26 16:22 GMT+01:00 Thomas Broyer <t.broyer@gmail.com>:


On Thursday, February 26, 2015 at 4:21:33 PM UTC+1, Thomas Broyer wrote:


On Thursday, February 26, 2015 at 2:59:43 PM UTC+1, Mickaël Leduque wrote:
So the answer to
When use it ? When not use it ?

is respectively always and never ? That's easy to follow, thanks!

Hmm, no. If your JSNI calls back into Java "synchronously", then you don't need to use $entry (exceptions will still "bubble" up to your GWT.UncaughtExceptionHandler Java→JSNI→Java, and you're still in the same event-loop wrt scheduled commands). You use $entry() whenever the browser calls back into your GWT/Java code "asynchronously" (event handling, promises, etc. basically whatever comes from the browser's own event loop).


Basically, whenever you pass a "callback" to be called "later", decorate it with $entry().

--
You received this message because you are subscribed to a topic in the Google Groups "Google Web Toolkit" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/luuAC9kq2-k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment