code: public static File getFile(URI resourceUri, String description) throws FileNotFoundException {
          if (!URL_PROTOCOL_FILE.equals(resourceUri.getScheme())) {
              throw new FileNotFoundException(
                  description + " cannot be resolved to absolute file path " +
                      "because it does not reside in the file system: " + resourceUri);
          }
          return new File(resourceUri.getSchemeSpecificPart());
      }
docs: Resolve the given resource URI to a <code>java.io.File</code>,
  i.e. to a file in the file system.
  
  @param resourceUri the resource URI to resolve
  @param description a description of the original resource that
  the URI was created for (for example, a class path location)
  @return a corresponding File object
  @throws FileNotFoundException if the URL cannot be resolved to
  a file in the file system