时间:2021-11-29 10:31:35 | 栏目: | 点击:次
下面一段代码是关于正在表达式判断是否为手机号码的代码,具体代码如下所述:
public static boolean isMobileNO(String mobile) {
Pattern p = Pattern
.compile("^((13[0-9])|(15[^4,\\D])|(18[0-9]))\\d{8}$");
Matcher m = p.matcher(mobile);
return m.matches();
}