Class PivotFacetHelper
- java.lang.Object
-
- org.apache.solr.handler.component.PivotFacetHelper
-
public class PivotFacetHelper extends Object
-
-
Constructor Summary
Constructors Constructor Description PivotFacetHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static List<String>decodeRefinementValuePath(String valuePath)Decodes a value path string specified for refinement.static StringencodeRefinementValuePath(List<String> values)Encodes a value path as a string for the purposes of a refinement requeststatic IntegergetCount(NamedList<Object> pivotList)static StringgetField(NamedList<Object> pivotList)static List<NamedList<Object>>getPivots(NamedList<Object> pivotList)static NamedList<Number>getQueryCounts(NamedList<Object> pivotList)static SimpleOrderedMap<SimpleOrderedMap<Object>>getRanges(NamedList<Object> pivotList)static NamedList<NamedList<NamedList<?>>>getStats(NamedList<Object> pivotList)static ComparablegetValue(NamedList<Object> pivotList)static Map<String,StatsValues>mergeStats(Map<String,StatsValues> merged, NamedList<NamedList<NamedList<?>>> remoteWrapper, org.apache.solr.handler.component.StatsInfo statsInfo)Given a mapping of keys toStatsValuesrepresenting the currently known "merged" stats (which may be null if none exist yet), and aNamedListcontaining the "stats" response block returned by an individual shard, this method accumulates the stats for eachStatsFieldfound in the shard response with the existing mergeStats
-
-
-
Method Detail
-
encodeRefinementValuePath
public static String encodeRefinementValuePath(List<String> values)
Encodes a value path as a string for the purposes of a refinement request
-
decodeRefinementValuePath
public static List<String> decodeRefinementValuePath(String valuePath)
Decodes a value path string specified for refinement.
-
getValue
public static Comparable getValue(NamedList<Object> pivotList)
- See Also:
PivotListEntry.VALUE
-
getField
public static String getField(NamedList<Object> pivotList)
- See Also:
PivotListEntry.FIELD
-
getCount
public static Integer getCount(NamedList<Object> pivotList)
- See Also:
PivotListEntry.COUNT
-
getPivots
public static List<NamedList<Object>> getPivots(NamedList<Object> pivotList)
- See Also:
PivotListEntry.PIVOT
-
getStats
public static NamedList<NamedList<NamedList<?>>> getStats(NamedList<Object> pivotList)
- See Also:
PivotListEntry.STATS
-
getQueryCounts
public static NamedList<Number> getQueryCounts(NamedList<Object> pivotList)
- See Also:
PivotListEntry.QUERIES
-
getRanges
public static SimpleOrderedMap<SimpleOrderedMap<Object>> getRanges(NamedList<Object> pivotList)
- See Also:
PivotListEntry.RANGES
-
mergeStats
public static Map<String,StatsValues> mergeStats(Map<String,StatsValues> merged, NamedList<NamedList<NamedList<?>>> remoteWrapper, org.apache.solr.handler.component.StatsInfo statsInfo)
Given a mapping of keys toStatsValuesrepresenting the currently known "merged" stats (which may be null if none exist yet), and aNamedListcontaining the "stats" response block returned by an individual shard, this method accumulates the stats for eachStatsFieldfound in the shard response with the existing mergeStats- Returns:
- the original
mergedMap after modifying, or a new Map if themergedparam was originally null. - See Also:
StatsInfo.getStatsField(java.lang.String),StatsValuesFactory.createStatsValues(org.apache.solr.handler.component.StatsField),StatsValues.accumulate(NamedList)
-
-