News
详细原因如下: java中,String 类下的 isEmpty ( ) 返回的只是 字符串的长度是否为0,如果 字符串为null 就会直接报空指针。 源码如下: public boolean isEmpty () { return count == 0; } android中,TextUtils.isEmpty (要判断的字符串) 会对 null 和长度进行判断,所以不会报空指针。
GoogleCodeExporter commented Mar 11, 2016 The problem is reproducible running an application that uses generic-dao with a java 5 jvm. Tip: use "java.lang.String.length ()==0" instead Error: ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results