GraphicalPdfComparer
Inheritance: java.lang.Object, com.aspose.pdf.comparison.graphicalcomparison.GraphicalPdfComparer
public class GraphicalPdfComparer extends Object
Represents a class for graphically comparing PDF documents. Should be used to search for small changes, mainly of a graphical nature. To compare text content changes, use other PDF comparison classes.
Constructors
| Constructor | Description |
|---|---|
| GraphicalPdfComparer | Creates an instance of {@link GraphicalPdfComparer} class. |
Methods
| Method | Description |
|---|---|
| compareDocumentsToImages | Compares documents graphically. |
| compareDocumentsToPdf | Compares documents graphically. The comparison result is placed in a PDF document. |
| comparePagesToImage | Compares pages graphically. The comparison result is placed in a image. |
| comparePagesToPdf | Compares pages graphically. The comparison result is placed in a PDF document. |
| comparePagesToPdf | Compares pages graphically. The comparison result is placed in a PDF document. |
| getColor | Gets and sets the change flag color. The default color is red. |
| getDifference | Gets differences between pages images. The result contains an image of the first page compared and an array of differences. |
| getResolution | Gets and sets the resolution of the resulting images. The default value is 150dpi. |
| getThreshold | Gets and sets the threshold value in percentage. This value allows you to ignore small changes if they are not significant to you. The default value is 0%. |
| setColor | Gets and sets the change flag color. The default color is red. |
| setResolution | Gets and sets the resolution of the resulting images. The default value is 150dpi. |
| setThreshold | Gets and sets the threshold value in percentage. This value allows you to ignore small changes if they are not significant to you. The default value is 0%. |
GraphicalPdfComparer
public GraphicalPdfComparer()
Creates an instance of {@link GraphicalPdfComparer} class.
compareDocumentsToImages
Compares documents graphically.
compareDocumentsToPdf
Compares documents graphically. The comparison result is placed in a PDF document.
comparePagesToImage
Compares pages graphically. The comparison result is placed in a image.
comparePagesToPdf
Compares pages graphically. The comparison result is placed in a PDF document.
comparePagesToPdf
Compares pages graphically. The comparison result is placed in a PDF document.
getColor
public final Color getColor()
Gets and sets the change flag color. The default color is red.
Returns: Color instance
getDifference
Gets differences between pages images. The result contains an image of the first page compared and an array of differences.
getResolution
public final Resolution getResolution()
Gets and sets the resolution of the resulting images. The default value is 150dpi.
Returns: Resolution instance
getThreshold
public final double getThreshold()
Gets and sets the threshold value in percentage. This value allows you to ignore small changes if they are not significant to you. The default value is 0%.
Returns: double value
setColor
Gets and sets the change flag color. The default color is red.
setResolution
Gets and sets the resolution of the resulting images. The default value is 150dpi.
setThreshold
public final void setThreshold(double value)
Gets and sets the threshold value in percentage. This value allows you to ignore small changes if they are not significant to you. The default value is 0%.
Parameters:
| Parameter | Type | Description |
|---|---|---|
| value | double value |