Class SearchSession
- java.lang.Object
-
- com.funnelback.publicui.search.model.transaction.session.SearchSession
-
public class SearchSession extends Object
Contains data associated with the current user and search session.
Session features must be enabled on the collection and the application container session management must be properly configured.
- Since:
- 12.5
-
-
Field Summary
Fields Modifier and Type Field Description private List<ClickHistory>
clickHistory
Click history of the user for the current collection.private List<CartResult>
resultsCart
Results cart of the user for the current collectionprivate List<SearchHistory>
searchHistory
Search history of the user for the current collection.private SearchUser
searchUser
User performing the search.
-
Constructor Summary
Constructors Constructor Description SearchSession()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
cartContains(String indexUrl)
Check if the cart contains a specific resultClickHistory
getClickHistory(String indexUrl)
Retrieve the clich history for a specific result
-
-
-
Field Detail
-
searchUser
private final SearchUser searchUser
User performing the search.
Will be the same across multiple searches for a given user.
-
searchHistory
private final List<SearchHistory> searchHistory
Search history of the user for the current collection.
-
clickHistory
private final List<ClickHistory> clickHistory
Click history of the user for the current collection.
-
resultsCart
private final List<CartResult> resultsCart
Results cart of the user for the current collection- Since:
- 12.4
-
-
Method Detail
-
cartContains
public boolean cartContains(String indexUrl)
Check if the cart contains a specific result- Parameters:
indexUrl
- URL of the result from the index- Returns:
- true if the cart contains this result, false otherwise
-
getClickHistory
public ClickHistory getClickHistory(String indexUrl)
Retrieve the clich history for a specific result- Parameters:
indexUrl
- URL of the result from the index- Returns:
- The click history, or null if this result wasn't clicked.
-
-