public final class Objects extends Object
public static Object coalesce(Object first, Object second)
null
object from the provided two objects. So, if the first object is not
null
, then it will be returned, otherwise the second object will be returned.first
- The first object.second
- The second object.null
object from the provided two objects.