摘要: String str = xxx; 1、判断一个字符串是否为空,首先就要确保他不是null,然后再判断他的长度。 if(str != null && str.length() != 0) { } 2、isEmpty完全等同于string.length()==0 if(string ==null || 阅读全文
posted @ 2020-09-25 18:22 yy0403 阅读(2169) 评论(0) 推荐(0)