读书人

spring_code_一

发布时间: 2013-11-22 23:06:19 作者: rapoo

spring_code_1
public static boolean isUrl(String resourceLocation) {
if (resourceLocation == null) {
return false;
}
if (resourceLocation.startsWith(CLASSPATH_URL_PREFIX)) {
return true;
}
try {
new URL(resourceLocation);
return true;
}
catch (MalformedURLException ex) {
return false;
}
}

读书人网 >软件架构设计

热点推荐