or_ method

On this page

or_

Combines this SearchCriteria with other criteria using logical OR operator.

def or_(self, other):
    ...
Parameter Type Description
other SearchCriteria Search criteria to combine with.

Returns: SearchCriteria: Combined search criteria.

Example

import groupdocs.watermark as gw
import groupdocs.watermark.search.searchcriteria as gws_sc

with gw.Watermarker("document.pdf") as watermarker:
    image_criteria = gws_sc.ImageDctHashSearchCriteria("logo.png")
    text_criteria = gws_sc.TextSearchCriteria("Company Name")
    combined = image_criteria.or_(text_criteria)
    possible = watermarker.search(combined)
    print("Found", possible.count, "possible watermark(s)")

See Also

On this page