java对象判空和字符串判空

参考:

  对象判空:http://www.ibloger.net/article/3209.html

  字符串判空:https://blog.csdn.net/qq_34926773/article/details/85235110

个人喜欢使用工具类hutool

  1. 对象判断: ObjectUtil.isEmpty(obj)

  2. 字符串判断: StrUtil.isEmpty(str)

posted @ 2020-11-03 16:17  爱就码上行动  阅读(344)  评论(0编辑  收藏  举报