Re: Refactoring to a Closure
Mirko Stocker <[email protected]>
| Newsgroups | gmane.comp.programming.refactoring |
|---|---|
| Message-ID | <[email protected]> |
Hi!
On Friday 18 December 2009 22:48:42 jcsextro wrote:
> I won't write any code using closures because a closure isn't the simplest
> thing that can work. I know this because of the millions of bits of code
> that I have already written in Java without closures.
But, if closures weren't even available in the languages you used, no wonder
you haven't had the chance to use them :-) How many times have you used an
anonymous class in Java? I'd bet that in most cases, passing a simple closure
would have done the job as well, and with much less code to write.
I'd recommend to take a look at Scala to see how Java with closures could look
like.
Regards
Mirko
------------------------------------
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/refactoring/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/refactoring/join
(Yahoo! ID required)
<*> To change settings via email:
[email protected]
[email protected]
<*> To unsubscribe from this group, send an email to:
[email protected]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/