docs: private static boolean deleteDir(final File pFile) throws IOException {
          // Recusively delete all files/subfolders
          // Deletes the files using visitor pattern, to avoid allocating
          // a file array, which may throw OutOfMemoryExceptions for
          // large directories/in low memory situations
          class DeleteFilesVisitor implements Visitor<File> {
              private int failedCount = 0;
              private IOException exception = null;
  
              public void visit(final File pFile) {
                  try {
                      if (!delete(pFile, true)) {
                          failedCount++;
                      }
                  }
                  catch (IOException e) {
                      failedCount++;
                      if (exception == null) {
                          exception = e;
                      }
                  }
              }
  
              boolean succeeded() throws IOException {
                  if (exception != null) {
                      throw exception;
                  }
                  return failedCount == 0;
              }
          }
          DeleteFilesVisitor fileDeleter = new DeleteFilesVisitor();
          visitFiles(pFile, null, fileDeleter);
  
          // If any of the deletes above failed, this will fail (or return false)
          return fileDeleter.succeeded() && pFile.delete();
      }