Package org.apache.solr.analytics.facet
Class ValueFacet
- java.lang.Object
 - 
- org.apache.solr.analytics.facet.AnalyticsFacet
 - 
- org.apache.solr.analytics.facet.SortableFacet
 - 
- org.apache.solr.analytics.facet.ValueFacet
 
 
 
 
- 
- All Implemented Interfaces:
 Consumer<String>,StreamingFacet
public class ValueFacet extends SortableFacet implements StreamingFacet, Consumer<String>
A facet that breaks up data by the values of a mapping expression or field. The mapping expression must be castable to aStringValueStream. 
- 
- 
Nested Class Summary
- 
Nested classes/interfaces inherited from class org.apache.solr.analytics.facet.SortableFacet
SortableFacet.FacetBucket, SortableFacet.FacetSortSpecification 
 - 
 
- 
Field Summary
- 
Fields inherited from class org.apache.solr.analytics.facet.SortableFacet
sort 
- 
Fields inherited from class org.apache.solr.analytics.facet.AnalyticsFacet
collectionManager, expressionCalculator, name, reductionData 
 - 
 
- 
Constructor Summary
Constructors Constructor Description ValueFacet(String name, StringValueStream expression) 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(String t)voidaddFacetValueCollectionTargets()Determine which facet values match the current document.StringValueStreamgetExpression()Get the expression used to create the facet values.- 
Methods inherited from class org.apache.solr.analytics.facet.SortableFacet
applyOptions, createOldResponse, createResponse, getSort, setSort 
- 
Methods inherited from class org.apache.solr.analytics.facet.AnalyticsFacet
exportFacetValue, exportShardData, getName, importFacetValue, importShardData, setExpressionCalculator, setReductionCollectionManager 
 - 
 
 - 
 
- 
- 
Constructor Detail
- 
ValueFacet
public ValueFacet(String name, StringValueStream expression)
 
 - 
 
- 
Method Detail
- 
addFacetValueCollectionTargets
public void addFacetValueCollectionTargets()
Description copied from interface:StreamingFacetDetermine which facet values match the current document. Add theReductionCollectionManager.ReductionDataCollections of the relevant facet values to the targets of the streamingReductionCollectionManagerso that they are updated with the current document's data.- Specified by:
 addFacetValueCollectionTargetsin interfaceStreamingFacet
 
- 
getExpression
public StringValueStream getExpression()
Get the expression used to create the facet values.- Returns:
 - a string mapping expression
 
 
 - 
 
 -