String

作者: Alan龙马 | 来源:发表于2019-10-10 13:42 被阅读0次

字符串比较
https://blog.csdn.net/qq_42934779/article/details/90488814

//字符串比较用 equals 不用 == 

//判断字符串是否为空
TextUtils.isEmpty(item.wechatopenid)
//字符串替换,判断首字符
if (result.startsWith(",")){
            result = result.replaceFirst(",", "");
        }
//替换指定位置的字符
StringBuilder sb = new StringBuilder(idcard);
                sb.replace(7, 10, "****");

                String mid = sb.toString();
                mid = mid.substring(0,15) + "***";
                return mid;

java截取某个字符之前或者之后的字符串
https://www.cnblogs.com/kkxwze/p/11224693.html

String总结
https://www.jianshu.com/p/501dd5991428
format
https://www.jianshu.com/p/db53c3453749
getString()
https://www.jianshu.com/p/abd81ce77659

相关文章

网友评论

      本文标题:String

      本文链接:https://www.haomeiwen.com/subject/ojnopctx.html