code: public synchronized void restore(File persistFile, List<File> contentDirs) {
          try {
              FileInputStream fileStream = new FileInputStream(persistFile);
              ObjectInputStream oStream = new ObjectInputStream(fileStream);
              log.info("Restoring changed list from backup: {}", persistFile.getAbsolutePath());
              synchronized (this) {
                  LinkedHashMap<String, ChangedFile> fileListFromDisk =
                      (LinkedHashMap<String, ChangedFile>) oStream.readObject();
  
                  //remove files in change list that are not in the content dir list.
                  if (contentDirs != null && !contentDirs.isEmpty()) {
  
                      Iterator<Entry<String, ChangedFile>> entries =
                          fileListFromDisk.entrySet().iterator();
                      while (entries.hasNext()) {
                          Entry<String, ChangedFile> entry = entries.next();
                          ChangedFile file = entry.getValue();
                          boolean watched = false;
                          for (File contentDir : contentDirs) {
                              if (file.getFile()
                                      .getAbsolutePath()
                                      .startsWith(contentDir.getAbsolutePath()) &&
                                  !this.fileExclusionManager.isExcluded(file.getFile())) {
                                  watched = true;
                                  break;
                              }
                          }
  
                          if (!watched) {
                              entries.remove();
                          }
                      }
                  }
  
                  this.fileList = fileListFromDisk;
              }
              oStream.close();
          } catch (Exception e) {
              throw new RuntimeException("Unable to restore File Changed List:" +
                                         e.getMessage(), e);
          }
      }
docs: Restores the state of the ChangedList using the given backup file
  
  @param persistFile file containing previous state
  @param contentDirs content directories currently configured.