public class PhoneFormatCheckUtils { public static boolean isMobile(String mobile) { String regex = "^((13[0-9])|(14[0,1,4-9])|(15[0-3,5-9])|(16[2,5,6,7])|(17[0-8])|(18[0-9])|(19[0-3,5-9]))\d{8}$"; Pattern p = Pattern.compile(regex); Matcher m = p.matcher(mobile); return m.matches(); } }
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)