RangeCombiner { public List<Filter> getReducedFilters() { if (rangeMap.isEmpty()) { return filters; } List<Filter> result = new ArrayList<>(otherFilters); for (Expression ex : new ArrayList<Expression>(rangeMap.keySet())) { MultiRange<?> multiRange = rangeMap.get(ex); addFiltersToResults(result, multiRange.toFilter(ff, ex)); } return result; } RangeCombiner(FilterFactory2 ff, FeatureType featureType, List<Filter> filters); List<Filter> getReducedFilters();  }
@Test public void testOtherFilter() { PropertyName label = ff.property("label"); Filter f1 = ff.greater(label, ff.literal("abc")); Filter f2 = ff.greater(label, ff.literal("adc")); Filter f3 = ff.notEqual(ff.function("random"), ff.property("i")); RangeCombiner rc = new RangeCombiner.And(ff, ft, Arrays.asList(f1, f2, f3)); List<Filter> reduced = rc.getReducedFilters(); assertEquals(2, reduced.size()); assertTrue(reduced.contains(f2)); assertTrue(reduced.contains(f3)); }