結果 : java check if object is null before calling method