@@ -0,0 +1,487 @@
+%0Apackage net.restlesscoder.sandbox;%0A%0Aimport java.util.function.Predicate;%0A%0Apublic class EqualsPredicate %7B%0A%0A%09public static void main(final String... args) %7B%0A%09%09// Why do we need Predicate.isEqual anyway?%0A%09%09// Why not just use obj::equals?%0A%09%09// Here's why!%0A%0A%09%09final Object obj = null;%0A%0A%09%09Predicate%3CObject%3E objEqualsSafe = Predicate.isEqual(obj);%0A%09%09System.out.println(objEqualsSafe.test(null));%0A%0A%09%09Predicate%3CObject%3E objEquals = obj::equals;%0A%09%09System.out.println(objEquals.test(null));%0A%09%7D%0A%0A%7D%0A

Add illustration where Predicate.isEqual is useful