docs: private void updateList(final Map<URI, URI> changeTable, final Map<URI, URI> conflictTable, final ChunkMapReader mapReader) {
          final URI xmlDitalist = job.tempDirURI.resolve("dummy.xml");
  
          final Set<URI> hrefTopics = new HashSet<>();
          final Set<URI> chunkTopicSet = mapReader.getChunkTopicSet();
          for (final FileInfo f : job.getFileInfo()) {
              final URI abs = job.tempDirURI.resolve(f.uri);
              if (f.isTarget && !chunkTopicSet.contains(abs)) {
                  hrefTopics.add(f.uri);
              }
          }
          for (final FileInfo f : job.getFileInfo()) {
              final URI abs = job.tempDirURI.resolve(f.uri);
              if (chunkTopicSet.contains(abs)) {
                  final URI s = f.uri;
                  if (s.getFragment() == null) {
                      // This entry does not have an anchor, we assume that this
                      // topic will
                      // be fully chunked. Thus it should not produce any output.
                      // The entry in hrefTopics points to the same target
                      // as entry in chunkTopics, it should be removed.
                      hrefTopics.removeIf(ent -> job.tempDirURI.resolve(ent).equals(
                              job.tempDirURI.resolve(s)));
                  } else {
                      hrefTopics.remove(s);
                  }
              }
          }
  
          // relative temporary files
          final Set<URI> topicList = new LinkedHashSet<>(128);
          final Set<URI> oldTopicList = new HashSet<>();
          for (final FileInfo f : job.getFileInfo()) {
              if (ATTR_FORMAT_VALUE_DITA.equals(f.format)) {
                  oldTopicList.add(f.uri);
              }
          }
          for (final URI t : hrefTopics) {
              topicList.add(t);
              oldTopicList.remove(t);
          }
  
          final Set<URI> chunkedTopicSet = new LinkedHashSet<>(128);
          final Set<URI> chunkedDitamapSet = new LinkedHashSet<>(128);
          final Set<URI> ditamapList = new HashSet<>();
          for (final FileInfo f : job.getFileInfo()) {
              if (ATTR_FORMAT_VALUE_DITAMAP.equals(f.format)) {
                  ditamapList.add(f.uri);
              }
          }
          for (final Map.Entry<URI, URI> entry : changeTable.entrySet()) {
              final URI oldFile = entry.getKey();
              final URI newFile = entry.getValue();
              if (newFile.equals(oldFile)) {
                  // newly chunked file
                  final URI newChunkedFile = getRelativePath(xmlDitalist, newFile);
                  final String extName = getExtension(newChunkedFile.getPath());
                  if (extName != null && !extName.equalsIgnoreCase(ATTR_FORMAT_VALUE_DITAMAP)) {
                      chunkedTopicSet.add(newChunkedFile);
                      if (!topicList.contains(newChunkedFile)) {
                          topicList.add(newChunkedFile);
                          // newly chunked file shouldn't be deleted
                          oldTopicList.remove(newChunkedFile);
                      }
                  } else {
                      if (!ditamapList.contains(newChunkedFile)) {
                          ditamapList.add(newChunkedFile);
                          oldTopicList.remove(newChunkedFile);
                      }
                      chunkedDitamapSet.add(newChunkedFile);
                  }
  
              }
          }
          // removed extra topic files
          for (final URI s : oldTopicList) {
              final File f = new File(job.tempDirURI.resolve(s));
              logger.debug("Delete " + f.toURI());
              if (f.exists() && !f.delete()) {
                  logger.error("Failed to delete " + f.getAbsolutePath());
              }
          }
  
          // TODO we have refined topic list and removed extra topic files, next
          // we need to clean up
          // conflictTable and try to resolve file name conflicts.
          for (final Map.Entry<URI, URI> entry : changeTable.entrySet()) {
              final URI oldFile = entry.getKey();
              final URI from = entry.getValue();
              if (from.equals(oldFile)) {
                  // original topic file
                  // FIXME
                  final URI targetPath = conflictTable.get(oldFile);
                  if (targetPath != null) {
                      final URI target = targetPath;
                      if (!new File(target).exists()) {
                          // newly chunked file
                          URI relativePath = getRelativePath(xmlDitalist, from);
                          final URI relativeTargetPath = getRelativePath(xmlDitalist, target);
                          if (relativeTargetPath.getPath().contains(URI_SEPARATOR)) {
                              relativePath2fix.put(relativeTargetPath,
                                      relativeTargetPath.getPath().substring(0, relativeTargetPath.getPath().lastIndexOf(URI_SEPARATOR) + 1));
                          }
                          // ensure the newly chunked file to the old one
                          try {
                              logger.debug("Delete " + target);
                              deleteQuietly(new File(target));
                              logger.debug("Move " + from + " to " + target);
                              moveFile(new File(from), new File(target));
                              final FileInfo fi = job.getFileInfo(from);
                              if (fi != null) {
                                  job.remove(fi);
                              }
                          } catch (final IOException e) {
                              logger.error("Failed to replace chunk topic: " + e.getMessage(), e);
  
                          }
                          topicList.remove(relativePath);
                          chunkedTopicSet.remove(relativePath);
                          relativePath = getRelativePath(xmlDitalist, target);
                          topicList.add(relativePath);
                          chunkedTopicSet.add(relativePath);
                      } else {
                          conflictTable.remove(oldFile);
                      }
                  }
              }
          }
  
          final Set<URI> all = new HashSet<>();
          all.addAll(topicList);
          all.addAll(ditamapList);
          all.addAll(chunkedDitamapSet);
          all.addAll(chunkedTopicSet);
  
          // remove redundant topic information
          for (final URI file : oldTopicList) {
              if (!all.contains(file)) {
                  final FileInfo fi = job.getFileInfo(file);
                  if (fi != null) {
                      job.remove(fi);
                  }
              }
          }
  
          for (final URI file : topicList) {
              // FIXME
              final FileInfo ff = job.getOrCreateFileInfo(stripFragment(file));
              ff.format = ATTR_FORMAT_VALUE_DITA;
          }
          for (final URI file : ditamapList) {
              final FileInfo ff = job.getOrCreateFileInfo(file);
              ff.format = ATTR_FORMAT_VALUE_DITAMAP;
          }
  
          for (final URI file : chunkedDitamapSet) {
              final FileInfo f = job.getOrCreateFileInfo(file);
              f.format = ATTR_FORMAT_VALUE_DITAMAP;
              f.isResourceOnly = false;
          }
          for (final URI file : chunkedTopicSet) {
              // FIXME
              final FileInfo f = job.getOrCreateFileInfo(stripFragment(file));
              f.format = ATTR_FORMAT_VALUE_DITA;
              f.isResourceOnly = false;
          }
  
          try {
              job.write();
          } catch (final IOException ex) {
              logger.error(ex.getMessage(), ex);
          }
      }