I’m testing out the comparison functionality with GroupDocs.Comparison specifically when comparing PDFs. I put together a quick test and the Words comparison works fine but the PDF comparison does not generate an error but also does not produce a document. Is there something I’m missing? I’m following the examples and these are pretty trivial tests. You can run the test by just running:
Yes, if you click the link you provided and go into the Examples and the file PdfDocumentsComparison.java you will see a method:
/*
* Comparing two pdf documents from streams, with settings and saving output
* to a resultant file
*/
public static void ComparePdfFromStreamToFile(String sourceFile, String targetFile) throws Throwable {
//ExStart:ComparePdfFromStreamToFile
// Create two streams of textFiles
InputStream sourceStream = Utilities.sourceStream(sourceFile);
InputStream targetStream = Utilities.targetStream(targetFile);
// Create instance of GroupDocs.Comparison.Comparison and call method
// Compare.
Comparison comparison = new Comparison();
InputStream result = comparison.compare(sourceStream, targetStream, Utilities.outputFileName(extension),
ComparisonType.Pdf, new PdfComparisonSettings());
//ExEnd:ComparePdfFromStreamToFile
}
That is functionally identical to the method I provided. The code example (TestRunner.java) is only 40 lines long so not much to review, but the method:
We are able to reproduce this issue at our end as well (output Pdf document is not generated with gradle). Hence, we have logged it in our internal issue tracking system. As we get any update from the concerned team, we will apprise you.
We have asked about the progress/state of this issue from the concerned team. Hence, as we get any update from them, we will notify you. Please stay tuned.