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;
  }
}

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 ; } }
return whether the given resource location is a url : either a special " classpath " pseudo url or a standard url .
