code: public static String fullPath(File file) {
          notNull("file", file);
          try {
              return file.getCanonicalPath();
          } catch (IOException e) {
              return file.getAbsolutePath();
          }
      }
docs: Gets the canonical path of the given file, or if that throws an exception then gets the absolute path.
  
  @param file The file to check
  @return The canonical or absolute path of the given file