public static String match(String value ,String complie){
String rs = null;
Pattern regular = Pattern.compile(complie);
Matcher matcher = regular.matcher(value);
if(matcher.find()){
rs = matcher.group(1);
}else{
rs = "没有匹配到想要的东西";
}
return rs;
}
java compile、matcher
猜你喜欢
转载自www.cnblogs.com/xiaomifeng0510/p/12694496.html
今日推荐
周排行