Class LogicalInverseRewriter

java.lang.Object
org.apache.parquet.filter2.predicate.LogicalInverseRewriter
All Implemented Interfaces:
FilterPredicate.Visitor<FilterPredicate>

public final class LogicalInverseRewriter extends Object implements FilterPredicate.Visitor<FilterPredicate>
Recursively removes all use of the not() operator in a predicate by replacing all instances of not(x) with the inverse(x), eg: not(and(eq(), not(eq(y))) -> or(notEq(), eq(y))

The returned predicate should have the same meaning as the original, but without the use of the not() operator.

See also LogicalInverter, which is used to do the inversion.