• Post Reply Bookmark Topic Watch Topic
  • New Topic

Useful tutorial about lambda expressions in java 8

 
Rodrigo Uchoa
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just thought I would share. This is one of the best tutorials on the topic:

https://rodrigouchoa.wordpress.com/2014/09/10/java-8-lambda-expressions-tutorial/
 
Stephan van Hulst
Bartender
Posts: 6583
84
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I like your article. I think it's well written and most of it looks correct. Maybe I can offer some critique later.

For now, I'll offer one comment. You have the following code snippet to demonstrate that you can shorten a multi-statement lambda to just a method call:
If you want to make this more declarative and even shorter, you can use a method handle instead:
Maybe you can insert a section before @FunctionalInterface to explain about Method Handles.

As a final remark, if you wish to promote your tutorial on our site, you might consider linking to our Java 8 forum from your article as well?
 
Rodrigo Uchoa
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Stephan!

Thanks for the feedback. I didn't mention method references on purpose, just so it wouldn't be too much to grasp at once. But I do recall making a remark about it somewhere in the article

As for the link, you're absolutely right. Will do that.

Regards,
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!