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

ConstructorDescription
GraphicalPdfComparerCreates an instance of {@link GraphicalPdfComparer} class.

Methods

MethodDescription
compareDocumentsToImagesCompares documents graphically.
compareDocumentsToPdfCompares documents graphically. The comparison result is placed in a PDF document.
comparePagesToImageCompares pages graphically. The comparison result is placed in a image.
comparePagesToPdfCompares pages graphically. The comparison result is placed in a PDF document.
comparePagesToPdfCompares pages graphically. The comparison result is placed in a PDF document.
getColorGets and sets the change flag color. The default color is red.
getDifferenceGets differences between pages images. The result contains an image of the first page compared and an array of differences.
getResolutionGets and sets the resolution of the resulting images. The default value is 150dpi.
getThresholdGets 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%.
setColorGets and sets the change flag color. The default color is red.
setResolutionGets and sets the resolution of the resulting images. The default value is 150dpi.
setThresholdGets 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:

ParameterTypeDescription
valuedouble value