code: public static File createLocalHash(File resource, String remoteLocation)
              throws ResourceDownloadError {
          File localHashFile;
          try {
              String contents = readFileToString(resource);
              String hashValue = hasher.hashValue(contents);
  
              String absPath = resource.getAbsolutePath();
              String localHashPath = absPath + SHA256_EXTENSION;
  
              localHashFile = new File(localHashPath);
              write(localHashFile, hashValue, UTF_8);
              return localHashFile;
          } catch (IOException e) {
              throw new ResourceDownloadError(remoteLocation, e.getMessage());
          }
      }
docs: Creates a hash of the contents of the {@link File} <tt>resource</tt> and
  writes it to a file alongside the real resource file.  The hash file
  can be found by appending {@link ResourceType#SHA256_EXTENSION} to the
  resource path.
  
  @param resource {@link File}, the local resource file
  @param remoteLocation {@link String}, the remote resource location
  @return {@link File}, the local hash file that was created
  @throws IOException Thrown if there was an IO error reading the local
  resource file, or writing the local hash file
  @throws ResourceDownloadError