code: public static Result fromFile(File file, Context context, ApplicationConfiguration configuration, Crypto crypto) {
          long lastModified = file.lastModified();
          String etag = computeEtag(lastModified, configuration, crypto);
          if (isNotModified(context, lastModified, etag)) {
              return new Result(Status.NOT_MODIFIED);
          } else {
              Result result = Results.ok(file);
              addLastModified(result, lastModified);
              addCacheControlAndEtagToResult(result, etag, configuration);
              return result;
          }
      }
docs: Computes the result to sent the given file. Cache headers are automatically set by this method.
  
  @param file          the file to send to the client
  @param context       the context
  @param configuration the application configuration
  @param crypto        the crypto service
  @return the result, it can be a NOT_MODIFIED if the file was not modified since the last request,
  or an OK result with the cache headers set.