Class GroupingSuggester
java.lang.Object
de.cxp.ocs.smartsuggest.querysuggester.GroupingSuggester
- All Implemented Interfaces:
QuerySuggester
,AutoCloseable
-
Field Summary
Fields inherited from interface de.cxp.ocs.smartsuggest.querysuggester.QuerySuggester
DEFAULT_MAXIMUM_RESULTS
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.cxp.ocs.smartsuggest.querysuggester.QuerySuggester
destroy, suggest
-
Constructor Details
-
GroupingSuggester
public GroupingSuggester()
-
-
Method Details
-
suggest
public List<Suggestion> suggest(String term, int maxResults, Set<String> tags) throws SuggestException - Specified by:
suggest
in interfaceQuerySuggester
- Parameters:
term
- the term for which to get suggestionsmaxResults
- the maximum number of suggestions to returntags
- the group names used for filtering- Returns:
- A list of suggestions for the given term
- Throws:
SuggestException
-
recordCount
public long recordCount()Description copied from interface:QuerySuggester
return amount of records indexed into this QuerySuggester.- Specified by:
recordCount
in interfaceQuerySuggester
- Returns:
- amount of indexed records
-
isReady
public boolean isReady()- Specified by:
isReady
in interfaceQuerySuggester
- Returns:
- true if ready to serve suggestions
-
close
- Specified by:
close
in interfaceAutoCloseable
- Throws:
Exception
-