code: public String getName() {
          int separatorIndex = path.lastIndexOf(separator);
          return (separatorIndex < 0) ? path : path.substring(separatorIndex + 1, path.length());
      }
docs: Returns the name of the file or directory represented by this file.
  
  @return this file's name or an empty string if there is no name part in
  the file's path.