public interface SearchFilter
Interface representing a search filter
-
Method Summary
Modifier and TypeMethodDescriptiondefault SearchFilterand(SearchFilter other) Overload for Groovy "bitwise and" operator.default SearchFilterOverload for Groovy "bitwise negate" operator.default SearchFilteror(SearchFilter other) Overload for Groovy "bitwise or" operator.default StringAlternative version oftoFilterString()that should be called when this filter is going to be combined with other filters in such a way that it might need to be wrapped with parentheses.
-
Method Details
-
toFilterString
String toFilterString()- Returns:
- This search filter, formatted into a string.
-
toFilterStringWrapped
Alternative version oftoFilterString()that should be called when this filter is going to be combined with other filters in such a way that it might need to be wrapped with parentheses. If that is the case, then this method should be overridden to do that.- Returns:
- The same as
toFilterString()but in a manner safe to use in a nested context.
-
or
Overload for Groovy "bitwise or" operator. Internally flattens nested levels, so that you can do something likex | y | zand it will be equivalent toor(x, y, z).- Parameters:
other- The filter to "or" with.- Returns:
- The result.
-
and
Overload for Groovy "bitwise and" operator. Internally flattens nested levels, so that you can do something likex & y & zand it will be equivalent toand(x, y, z).- Parameters:
other- The filter to "and" with.- Returns:
- The result.
-
bitwiseNegate
Overload for Groovy "bitwise negate" operator.- Returns:
- The negated filter.
-