Re:Java Pain
by haddr on Friday June 20, 2014 @03:49PM
(#7922512)
Ad 2: Things evolve. If you stopped somwhere in the mid 90, you won't notice. But in Java 8 you can do null checking easily using Optional. Your example would be:
String address = a.map(A::b).map(B::c).map(C::d).orElse("UNKNOWN");
[ Parent
| on HN ]