Links

  • 1. Sogeti
  • 2. JBoss
  • 3. IBM
  • 4. Oracle
  • 5. SpringSource
  • 6. NL-JUG
  • 7. Java

Archives

Syndication  RSS 2.0

RSS 1.0
RSS 2.0

Bookmark this site

Add 'JCN Blog' site to delicious  Add 'JCN Blog' site to technorati  Add 'JCN Blog' site to digg  Add 'JCN Blog' site to dzone

Posted by Rino Kadijk at 9:44 on Wednesday 16 July    Add 'Closures for Java' site to delicious  Add 'Closures for Java' site to technorati  Add 'Closures for Java' site to digg  Add 'Closures for Java' site to dzone

Wat zijn Closures? Op de blog van Neal Gafter staat het volgende:

Modern programming languages provide a mixture of primitives for composing programs. C#, Javascript, Ruby, Scala, and Smalltalk (to name just a few) have direct language support for function types and inline function-valued expression, called closures. A proposal for closures is working its way through the C++ standards committees as well. Function types provide a natural way to express some kinds of abstraction that are currently quite awkward to express in Java. For programming in the small, closures allow one to abstract an algorithm over a piece of code; that is, they allow one to more easily extract the common parts of two almost-identical pieces of code. For programming in the large, closures support APIs that express an algorithm abstracted over some computational aspect of the algorithm. We propose to add function types and closures to Java. We anticipate that the additional expressiveness of the language will simplify the use of existing APIs and enable new kinds of APIs that are currently too awkward to express using the best current idiom: interfaces and anonymous classes.

14 december 2007 werd er een bericht op JCN Blog
geplaatst over de presentatie van Joshua Bloch over closure support in Java. Vervolgens reageerde James Gosling als volgt op zijn blog:

There has been a lot of chatter about the closures proposal penned by Neal Gafter. And, in particular, whether or not I support it. I absolutely do.

Volgens de blog van Neal Gafter lijkt de specificatie eraan te komen voor JDK 7. Hij schrijft het volgende:

I’m co-author of a draft proposal for adding support for closures to the Java programming language for the Dolphin (JDK 7) release. It was carefully designed to interoperate with the current idiom of one-method interfaces. An abbreviated version of the original proposal is reproduced below. The latest version of the proposal and a prototype can be found at http://www.javac.info/.

Gilad Bracha, Neal Gafter, James Gosling, Peter von der Ahé

In zijn videopresentatie legt Neal Gafter uit welke voordelen Closures bieden ten opzichte van de huidige mogelijkheden.

http://gafter.blogspot.com/2006/08/closures-for-java.html
http://www.javac.info/
http://www.parleys.com/display/PARLEYS/Home#talk=5210267;title=The%20Closures%20Controversy;slide=51
http://java.sogeti.nl/blogs/ontheroad/index.php/2007/12/14/the-closures-controversy-door-joshua-bloch/#more-423
http://blogs.sun.com/jag/entry/closures
http://video.google.com/videoplay?docid=4051253555018153503


© 2020 Java Competence Network. All Rights Reserved.