Interface RapidViewHistoryService
- All Known Implementing Classes:
RapidViewHistoryServiceImpl
public interface RapidViewHistoryService
Stores recently viewed rapid view ids for a given user.
-
Method Summary
Modifier and TypeMethodDescriptionio.atlassian.fugue.Option
<RapidView> findMostRecentInProject
(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project) Get the most recent rapid view for the projectgetAllRecentViews
(com.atlassian.jira.user.ApplicationUser user) Get the most recent rapid views, ordered by most recently visitedgetMostRecent
(com.atlassian.jira.user.ApplicationUser user) Get the most recent rapid viewio.atlassian.fugue.Option
<RapidView> getMostRecentRapidViewFromList
(com.atlassian.jira.user.ApplicationUser user, Collection<RapidView> rapidViews) Returns the rapid view from the given list of rapid views which the user visited most recentlygetRecentViews
(com.atlassian.jira.user.ApplicationUser user, int count) Get the number of recent views for the specified uservoid
storeRapidView
(com.atlassian.jira.user.ApplicationUser user, RapidView rapidView) Store a rapid view in the history
-
Method Details
-
storeRapidView
Store a rapid view in the history- Parameters:
user
- the user to find; may be null
-
getAllRecentViews
Get the most recent rapid views, ordered by most recently visited- Parameters:
user
- the user to find; may be null- Returns:
- a list of views
-
getRecentViews
@Nonnull List<RapidView> getRecentViews(@Nullable com.atlassian.jira.user.ApplicationUser user, int count) Get the number of recent views for the specified user- Parameters:
user
- the user to find; may be nullcount
- the number of recent views to return- Returns:
- a list of views
-
getMostRecent
Get the most recent rapid view- Parameters:
user
- the user to find; may be null- Returns:
- a view or null if none found
-
findMostRecentInProject
io.atlassian.fugue.Option<RapidView> findMostRecentInProject(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project) Get the most recent rapid view for the project- Parameters:
user
- the user to find; may be null- Returns:
- optional rapid view
-
getMostRecentRapidViewFromList
io.atlassian.fugue.Option<RapidView> getMostRecentRapidViewFromList(com.atlassian.jira.user.ApplicationUser user, Collection<RapidView> rapidViews) Returns the rapid view from the given list of rapid views which the user visited most recently- Parameters:
user
- the user to find; may be nullrapidViews
- Collection of rapid views to test- Returns:
- Option with the most recent rapid view from the list
-