public static int string2Int(String source) {
if(source==null||source.trim().length()==0){
throw new RuntimeException("当string2Int时出错,source="+source);
}
return Integer.parseInt(source);
}
RuntimeException不需要捕获
最新推荐文章于 2023-05-28 14:55:39 发布