Hello there,

i wonder if there are plans to allow developers to use lambdas/method 
references for requestfactory.

my idea was that there could be some overloaded versions of 
fire(Receiver<T>) and to(Receiver<T>) that accept 1-3 lamdbas (4 if the 
deprecated onViolation should be supported here too).

e.g
fire(Receiver<T>) // the original
fire(SuccessReceiver<T>) // only the success callback
fire(SuccessReceiver<T>, FailureReceiver) // the success + failure callback
fire(SuccessReceiver<T>, ConstraintViolationReceiver) // the success + 
ConstraintViolation callback
fire(SuccessReceiver<T>, FailureReceiver, ConstraintViolationReceiver) // 
the success + failure + ConstraintViolation callback

same for to() of course.

the implementation could be something like: all lambda supporting methods 
call the one with the Receiver parameter with an assembled Receiver that 
forwards its calls to the corresponding lambda.


-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/b33b86ac-e2e9-4e9d-a6d5-a4efdfa9117e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to