A
- the actual type of AmetysObject
s.public static class FrontOfficeSearcherFactory.FrontOfficeSolrSearchResults<A extends AmetysObject> extends Object implements SearchResults<A>
SolrSearchResults
for AbstractSearchGenerator
(add the possibility to add facet.queries)Modifier and Type | Field and Description |
---|---|
private Map<String,Integer> |
_facetQueryResults |
private SearchResults<A> |
_searchResults |
Constructor and Description |
---|
FrontOfficeSolrSearchResults(SearchResults<A> searchResults,
QueryResponse response,
Map<String,Integer> facetQueryResults)
Build a FrontOfficeSolrSearchResults object.
|
Modifier and Type | Method and Description |
---|---|
Map<String,Integer> |
getFacetQueryResults()
Gets the facet.query results as a Map
|
Map<String,Map<String,Integer>> |
getFacetResults()
Get the facet results as a Map, indexed by faceted criterion ID.
The Map values are represented by a Map of value -> result count. |
float |
getMaxScore()
Get the maximum score of all the results.
|
Iterable<String> |
getObjectIds()
Get the result IDs.
|
AmetysObjectIterable<A> |
getObjects()
Get the
AmetysObject results |
SearchResultsIterable<SearchResult<A>> |
getResults()
Get the
Iterable of the search results. |
long |
getTotalCount()
Get the total number of search results.
|
private Map<String,Integer> _facetQueryResults
private SearchResults<A extends AmetysObject> _searchResults
public FrontOfficeSolrSearchResults(SearchResults<A> searchResults, QueryResponse response, Map<String,Integer> facetQueryResults)
searchResults
- The wrapped SearchResults
objectresponse
- the solr search response.facetQueryResults
- The facet.query results.public SearchResultsIterable<SearchResult<A>> getResults()
SearchResults
Iterable
of the search results.getResults
in interface SearchResults<A extends AmetysObject>
SearchResultsIterable
on the SearchResult
.public AmetysObjectIterable<A> getObjects()
SearchResults
AmetysObject
resultsgetObjects
in interface SearchResults<A extends AmetysObject>
AmetysObjectIterable
on the results.public Iterable<String> getObjectIds()
SearchResults
getObjectIds
in interface SearchResults<A extends AmetysObject>
Iterable
on the content IDs.public Map<String,Map<String,Integer>> getFacetResults()
SearchResults
getFacetResults
in interface SearchResults<A extends AmetysObject>
public Map<String,Integer> getFacetQueryResults()
public long getTotalCount()
SearchResults
getTotalCount
in interface SearchResults<A extends AmetysObject>
public float getMaxScore()
SearchResults
getMaxScore
in interface SearchResults<A extends AmetysObject>