Package de.cxp.ocs.elasticsearch.facets
Interface FacetCreator
-
- All Known Implementing Classes:
CategoryFacetCreator,IntervalFacetCreator,NestedFacetCreator,RangeFacetCreator,TermFacetCreator,VariantFacetCreator
public interface FacetCreator
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.elasticsearch.search.aggregations.AggregationBuilderbuildAggregation()Build aggregation that is necessary to create the according facets.org.elasticsearch.search.aggregations.AggregationBuilderbuildExcludeFilteredAggregation(Set<String> excludeNames)Build aggregation that is necessary to create the facets, but not the ones in the exlude list.org.elasticsearch.search.aggregations.AggregationBuilderbuildIncludeFilteredAggregation(Set<String> includeNames)Build aggregation that is necessary to create the facets specified by the includes list.Collection<Facet>createFacets(org.elasticsearch.search.aggregations.Aggregations aggResult, FilterContext filterContext, SearchQueryBuilder linkBuilder)create facets from aggregation result.Optional<Facet>mergeFacets(Facet first, Facet second)Try to merge facets with same label.
-
-
-
Method Detail
-
buildAggregation
org.elasticsearch.search.aggregations.AggregationBuilder buildAggregation()
Build aggregation that is necessary to create the according facets.- Returns:
-
buildIncludeFilteredAggregation
org.elasticsearch.search.aggregations.AggregationBuilder buildIncludeFilteredAggregation(Set<String> includeNames)
Build aggregation that is necessary to create the facets specified by the includes list.- Parameters:
includeNames-- Returns:
-
buildExcludeFilteredAggregation
org.elasticsearch.search.aggregations.AggregationBuilder buildExcludeFilteredAggregation(Set<String> excludeNames)
Build aggregation that is necessary to create the facets, but not the ones in the exlude list.- Parameters:
excludeNames-- Returns:
-
createFacets
Collection<Facet> createFacets(org.elasticsearch.search.aggregations.Aggregations aggResult, FilterContext filterContext, SearchQueryBuilder linkBuilder)
create facets from aggregation result.- Parameters:
aggResult-filterContext-linkBuilder-- Returns:
-
-