Search This Blog

Wednesday, 28 October 2015

Interfaces and Default Methods

In an earlier post, I covered one of Java 8's new features - default methods in interfaces. While I did the pros there were some corner cases to be considered when implementing this feature.

Tuesday, 20 October 2015

The BiVersions of Java FunctionalInterfaces

In the previous post, we saw a version of the Function class that took two parameters into apply instead of one. Similar to the BiFunction interface, we also have BiPredicate, BinaryOperator, and BiSupplier .

Wednesday, 7 October 2015

Variations in java functions

In the previous post, we saw the Function Interface that takes an object of one type and transforms it into an object of another type. Consider the user case where we need to split a string and retain only the second half.