RotateAngleSearchCriteria

Inheritance: java.lang.Object, com.groupdocs.watermark.search.SearchCriteria

public class RotateAngleSearchCriteria extends SearchCriteria

Represents criteria allowing filtering by watermark rotate angle.

Learn more:

The following example demonstrates how to find and remove watermarks using search criteria.

Watermarker watermarker = new Watermarker(“C:\test.some_ext”); SizeSearchCriteria widthRange = new SizeSearchCriteria(Dimension.Width, 50, 100); RotateAngleSearchCriteria rotateAngle = new RotateAngleSearchCriteria(0, 45); TextSearchCriteria textCriteria = new TextSearchCriteria(Pattern.compile("^Test watermark$"));

PossibleWatermarkCollection watermarks = watermarker.search(textCriteria.and(widthRange.or(rotateAngle))); watermarks.clear();

watermarker.save(“C:\modified_test.some_ext”); watermarker.close();

Constructors

Constructor Description
RotateAngleSearchCriteria(double minAngle, double maxAngle) Initializes a new instance of the [RotateAngleSearchCriteria](../../com.groupdocs.watermark.search/rotateanglesearchcriteria) class with a starting angle and a ending angle.

Methods

Method Description
getMinimumAngle() Gets the starting angle in degrees.
getMaximumAngle() Gets the ending angle in degrees.
isSatisfiedBy(PossibleWatermark candidate)
accept(ICriteriaVisitor visitor)

RotateAngleSearchCriteria(double minAngle, double maxAngle)

public RotateAngleSearchCriteria(double minAngle, double maxAngle)

Initializes a new instance of the [RotateAngleSearchCriteria](../../com.groupdocs.watermark.search/rotateanglesearchcriteria) class with a starting angle and a ending angle.

Parameters:

Parameter Type Description
minAngle double The starting angle in degrees.
maxAngle double The ending angle in degrees.

getMinimumAngle()

public final double getMinimumAngle()

Gets the starting angle in degrees.

Returns: double - The starting angle.

getMaximumAngle()

public final double getMaximumAngle()

Gets the ending angle in degrees.

Returns: double - The ending angle.

isSatisfiedBy(PossibleWatermark candidate)

public boolean isSatisfiedBy(PossibleWatermark candidate)

Parameters:

Parameter Type Description
candidate PossibleWatermark

Returns: boolean

accept(ICriteriaVisitor visitor)

public void accept(ICriteriaVisitor visitor)

Parameters:

Parameter Type Description
visitor ICriteriaVisitor