code: public void transform(final File inputFile, final List<XMLFilter> filters) throws DITAOTException {
          final File outputFile = new File(inputFile.getAbsolutePath() + FILE_EXTENSION_TEMP);
          transformFile(inputFile, outputFile, filters);
          try {
              deleteQuietly(inputFile);
              moveFile(outputFile, inputFile);
          } catch (final RuntimeException e) {
              throw e;
          } catch (final Exception e) {
              throw new DITAOTException("Failed to replace " + inputFile + ": " + e.getMessage());
          }
      }
docs: Transform file with XML filters.
  
  @param inputFile file to transform and replace
  @param filters XML filters to transform file with, may be an empty list