by elrodeo · 15y ago · 0 comments
Want to filter list with an "ad-hoc" function in Java? Use
Collections2.filter(list, new Predicate<Integer>() { public boolean apply(Integer i) { return i % 2 == 0; } })
from the Guava library. To read a file I use
Utils.getFileContent("filename")
from my library.
You would say, that the Java verbosity is outsourced to external libraries — but so it is in Ruby as well. The only difference is that Ruby contains more libraries than Java. But does it count in a development of a huge professional project? NO. (You write the libraries once and use the package everywhere.) Does it count in script writing? Yes. But Java wasn't designed for script writing, so please please don't compare a fork and a spoon.
No comments yet.