public static Uri getUriForFile(File file) {
    return Uri.fromFile(file);
  }
Returns a URI for a given file using {@link Uri#fromFile(File)}.

@param file a file with a valid path
@return the URI
fbcore/src/main/java/com/facebook/common/util/UriUtil.java