code: public static void writeStringToFile(File file, String content) throws IOException {
          OutputStream outputStream = getOutputStream(file);
          outputStream.write(content.getBytes());
      }
docs: Write string to file.
  
  @param file    the file
  @param content the content
  @throws IOException the io exception