code: public String readFileContent(File file) {
          StringBuilder fileContentBuilder = new StringBuilder();
          if (file.exists()) {
              String stringLine;
              try {
                  FileReader fileReader = new FileReader(file);
                  BufferedReader bufferedReader = new BufferedReader(fileReader);
                  while ((stringLine = bufferedReader.readLine()) != null) {
                      fileContentBuilder.append(stringLine + "\n");
                  }
                  bufferedReader.close();
                  fileReader.close();
              } catch (FileNotFoundException e) {
                  e.printStackTrace();
              } catch (IOException e) {
                  e.printStackTrace();
              }
          }
  
          return fileContentBuilder.toString();
      }
docs: Reads a content from a file.
  This is an I/O operation and this method executes in the main thread, so it is recommended to
  perform the operation using another thread.
  
  @param file The file to read from.
  @return A string with the content of the file.