Module org.elasticsearch.compute
Class TopNMultivalueDedupeBytesRef
java.lang.Object
org.elasticsearch.compute.operator.mvdedupe.TopNMultivalueDedupeBytesRef
Removes duplicate values from multivalued positions, and keeps only the ones that pass the predicate.
Clone of MultivalueDedupeBytesRef, but it accepts a predicate and nulls flag to filter the values
in a top-N aggregation context. Values not in the top-N produce null group ids so the corresponding
aggregator state is never allocated.
-
Constructor Summary
ConstructorsConstructorDescriptionTopNMultivalueDedupeBytesRef(BytesRefBlock block, boolean acceptNulls, Predicate<org.apache.lucene.util.BytesRef> isAcceptable) -
Method Summary
Modifier and TypeMethodDescriptionhashAdd(BlockFactory blockFactory, BytesRefHashTable hash) Dedupe values, add them to the hash, and build anIntBlockof their hashes.hashLookup(BlockFactory blockFactory, BytesRefHashTable hash) Dedupe values and build anIntBlockof their hashes.
-
Constructor Details
-
TopNMultivalueDedupeBytesRef
public TopNMultivalueDedupeBytesRef(BytesRefBlock block, boolean acceptNulls, Predicate<org.apache.lucene.util.BytesRef> isAcceptable)
-
-
Method Details
-
hashAdd
Dedupe values, add them to the hash, and build anIntBlockof their hashes. This block is suitable for passing as the grouping block to aGroupingAggregatorFunction. -
hashLookup
Dedupe values and build anIntBlockof their hashes. This block is suitable for passing as the grouping block to aGroupingAggregatorFunction.
-