diff --git a/processing/src/main/java/io/druid/query/filter/Filter.java b/processing/src/main/java/io/druid/query/filter/Filter.java index 2ff6033b197..9a8f6836422 100644 --- a/processing/src/main/java/io/druid/query/filter/Filter.java +++ b/processing/src/main/java/io/druid/query/filter/Filter.java @@ -25,12 +25,6 @@ import io.druid.query.DefaultBitmapResultFactory; import io.druid.segment.ColumnSelector; import io.druid.segment.ColumnSelectorFactory; -/** - * {@link #getBitmapIndex} and {@link #getBitmapResult} methods both have default implementations, delegating to each - * other. Every implementation of {@link Filter} should override {@link #getBitmapResult}, currently it has a default - * implementation for compatibility with Filters in extensions. In Druid 0.11 {@link #getBitmapResult} is going to - * become an abstract method without a default implementation. - */ public interface Filter { /** @@ -38,6 +32,8 @@ public interface Filter * {@link #supportsBitmapIndex(BitmapIndexSelector)} returns true. Behavior in the case that * {@link #supportsBitmapIndex(BitmapIndexSelector)} returns false is undefined. * + * This method is OK to be called, but generally should not be overridden, override {@link #getBitmapResult} instead. + * * @param selector Object used to retrieve bitmap indexes * * @return A bitmap indicating rows that match this filter. @@ -60,10 +56,7 @@ public interface Filter * * @see Filter#estimateSelectivity(BitmapIndexSelector) */ - default T getBitmapResult(BitmapIndexSelector selector, BitmapResultFactory bitmapResultFactory) - { - return bitmapResultFactory.wrapUnknown(getBitmapIndex(selector)); - } + T getBitmapResult(BitmapIndexSelector selector, BitmapResultFactory bitmapResultFactory); /** * Estimate selectivity of this filter.