public void revert(List<PatchAction> actions, File backupDir, File rootDir, UpdaterUI ui) throws IOException {
    LOG.info("Reverting... [" + actions.size() + " actions]");
    ui.startProcess(UpdaterUI.message("reverting"));

    List<PatchAction> reverse = new ArrayList<>(actions);
    Collections.reverse(reverse);
    File toDir = toBaseDir(rootDir);

    for (int i = 0; i < reverse.size(); i++) {
      reverse.get(i).revert(toDir, backupDir);
      ui.setProgress((i + 1) * 100 / reverse.size());
    }
  }
public void revert(List<PatchAction> actions, File backupDir, File rootDir, UpdaterUI ui)