As you know, java.util.Objects is
This class consists of static utility methods for operating on objects.
One of such methods i
Look at the source:
public static boolean isNull(Object obj) {
return obj == null;
}
To check for null
values, you can use:
Objects.isNull(myObject)
null == myObject // avoids assigning by typo
myObject == null // risk of typo
The fact that Objects.isNull
is meant for Predicate
s does not prevent you from using it as above.