1.使用正则删除非数字
str = str.replaceAll("\\D+","");
2.Google Guava
CharMatcher.inRange('0','9').retainFrom("123-456-789")
或
String input = "My phone number is 123-456-789!";
String output = CharMatcher.is('-').or(CharMatcher.DIGIT).retainFrom(input); // output 123-456-789
最新评论
什么时候出新版啊已经过了半个月了
有没有港台节目直播?
One Drive提取密码?
大佬请问每次都需要在plugins中启动tiktok吗,还是直接启动app