docs: private void pullTopicMetadata(final AbstractPipelineInput input, final Collection<FileInfo> fis) throws DITAOTException {
          // Pull metadata (such as navtitle) into the map from the referenced topics
          final File styleFile = new File(input.getAttribute(ANT_INVOKER_EXT_PARAM_STYLE));
          for (final FileInfo f : fis) {
              final File inputFile = new File(job.tempDir, f.file.getPath());
              final File tmp = new File(inputFile.getAbsolutePath() + ".tmp" + Long.toString(System.currentTimeMillis()));
              if (!tmp.getParentFile().exists() && !tmp.getParentFile().mkdirs()) {
                  throw new DITAOTException("Failed to create directory " + tmp.getParent());
              }
              logger.info("Processing " + inputFile.toURI());
              logger.debug("Processing " + inputFile.toURI() + " to " + tmp.toURI());
  
              Source source = null;
              Result result = null;
              try {
                  source = new StreamSource(inputFile.toURI().toString());
                  result = new StreamResult(tmp);
  
                  logger.info("Loading stylesheet " + styleFile);
                  final TransformerFactory tf = TransformerFactory.newInstance();
                  final CatalogResolver xmlCatalog = CatalogUtils.getCatalogResolver();
                  tf.setURIResolver(xmlCatalog);
                  final Transformer t = withLogger(tf.newTransformer(new StreamSource(styleFile)), logger);
                  final URIResolver resolver;
                  if (Configuration.DEBUG) {
                      resolver = new DebugURIResolver(xmlCatalog);
                  } else {
                      resolver = xmlCatalog;
                  }
                  t.setURIResolver(resolver);
                  for (Entry<String, String> e : input.getAttributes().entrySet()) {
                      logger.debug("Set parameter " + e.getKey() + " to '" + e.getValue() + "'");
                      t.setParameter(e.getKey(), e.getValue());
                  }
  
                  t.transform(source, result);
              } catch (final TransformerConfigurationException e) {
                  throw new RuntimeException("Failed to compile stylesheet '" + styleFile.toURI() + "': " + e.getMessage(), e);
              } catch (final Exception e) {
                  throw new DITAOTException("Failed to transform document: " + e.getMessage(), e);
              } finally {
                  try {
                      XMLUtils.close(source);
                  } catch (final IOException e) {
                      // NOOP
                  }
                  try {
                      XMLUtils.close(result);
                  } catch (final IOException e) {
                      // NOOP
                  }
              }
              try {
                  logger.debug("Moving " + tmp.toURI() + " to " + inputFile.toURI());
                  if (!inputFile.delete()) {
                      throw new IOException("Failed to to delete input file " + inputFile.toURI());
                  }
                  if (!tmp.renameTo(inputFile)) {
                      throw new IOException("Failed to to replace input file " + inputFile.toURI());
                  }
              } catch (final IOException e) {
                  throw new DITAOTException("Failed to replace document: " + e.getMessage(), e);
              } finally {
                  logger.debug("Remove " + tmp.toURI());
                  FileUtils.delete(tmp);
              }
          }
      }