public static String StringFilter(String str){
// 清除所有特殊字符
String regEx = "[`~!@#$%^&*()+=|{}':;',//[//].<>/?~!@#¥%……&*()——+|{}【】‘;:”“’。,、?●§№☆★○◎◇◆□■△▲※#&@\^_ ̄―♂♀]";
Pattern p = Pattern.compile(regEx);
Matcher m = p.matcher(str);
return m.replaceAll("").trim();
}
// 清除所有特殊字符
String regEx = "[`~!@#$%^&*()+=|{}':;',//[//].<>/?~!@#¥%……&*()——+|{}【】‘;:”“’。,、?●§№☆★○◎◇◆□■△▲※#&@\^_ ̄―♂♀]";
Pattern p = Pattern.compile(regEx);
Matcher m = p.matcher(str);
return m.replaceAll("").trim();
}

9万+

被折叠的 条评论
为什么被折叠?



