public static boolean isNumeric1(String str){
str=str.trim().replaceAll(" ", "");
Pattern pattern = Pattern.compile("[0-9]*");
return pattern.matcher(str).matches();
}
public static boolean isNumeric1(String str){
str=str.trim().replaceAll(" ", "");
Pattern pattern = Pattern.compile("[0-9]*");
return pattern.matcher(str).matches();
}
转载于:https://my.oschina.net/arrom/blog/224646