public static class CountCollector.ExpressionCountCollector extends CountCollector
count(expr) expression. This collects 3 values:
docCount - The number of Solr Documents for which the wrapped expression exists.
count - The number of values which wrapped expression contains.
missing - The number of Solr Documents for which the wrapped expression does not exist.CountCollector.CountData, CountCollector.ExpressionCountCollector, CountCollector.TotalCountCollectornamecollectionTargets, ioData, lastingTargets| Constructor and Description |
|---|
ExpressionCountCollector(AnalyticsValueStream param) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
apply(CountCollector.CountData data)
Apply the collected info to the given reduction data.
|
void |
collect()
Collect the information from current Solr Document.
|
long |
missing()
The number of Solr Documents for which the given analytics expression does not exist.
|
void |
setData(ReductionData data)
Finalize the reduction with the collected data stored in the parameter.
|
void |
setMergedData(ReductionData data)
Finalize the reduction with the merged data stored in the parameter.
|
void |
submitReservations(Consumer<ReductionDataReservation<?,?>> consumer)
Submits the data reservations needed for this data collector.
|
count, docCount, getExpressionStr, getName, newDataaddCollectTarget, addLastingCollectTarget, clearLastingCollectTargets, collectAndApply, dataIO, newDataIO, newDataTargetpublic ExpressionCountCollector(AnalyticsValueStream param)
public long missing()
public void setMergedData(ReductionData data)
ReductionDataCollectorReductionFunctions that use this
data collector act like regular AnalyticsValue classes that
can be accessed through their get<value-type> methods.
(FOR CLOUD)setMergedData in class CountCollectordata - the merged data to compute a reduction forpublic void setData(ReductionData data)
ReductionDataCollectorReductionFunctions that use this
data collector act like regular AnalyticsValue classes that
can be accessed through their get<value-type> methods.
(FOR SINGLE-SHARD)setData in class CountCollectordata - the collected data to compute a reduction forpublic void collect()
ReductionDataCollectorcollect in class ReductionDataCollector<CountCollector.CountData>protected void apply(CountCollector.CountData data)
ReductionDataCollectorReductionDataCollector.collect() call.apply in class ReductionDataCollector<CountCollector.CountData>data - reduction data to apply collected info topublic void submitReservations(Consumer<ReductionDataReservation<?,?>> consumer)
ReductionDataCollectorsubmitReservations in class CountCollectorconsumer - the consumer which the reservations are submitted toCopyright © 2000-2018 Apache Software Foundation. All Rights Reserved.