摘要: 1 1. public static boolean isEmpty(String str) 2 3 判断某字符串是否为空,为空的标准是 str==null 或 str.length()==0 4 5 下面是 StringUtils 判断是否为空的示例: 6 7 StringUtils.isEmpty(null) = true 8 9 StringUtils.isEmpty("") = true10 11 StringUtils.isEmpty(" ") = false //注意在 StringUtils 中空格作非空处理 12 13 Stri... 阅读全文
posted @ 2012-11-01 10:06 雲端之風 阅读(1579) 评论(0) 推荐(1) 编辑