Interface ContentViewService
-
- All Known Implementing Classes:
ContentViewServiceImpl
public interface ContentViewServiceThis interface abstracts out the Business Logic services available for this micro-service.- Author:
- swaroop_nath
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description List<Feed>fetchRecentFeed(String currentUserID)A service that lets the currently logged-in user fetch the recent feed for them.voidregisterReport(Map<String,Object> payload)A service that lets the user to register a report against a memory.voidupdateMemoryWithComment(String memoryID, String currentUserID, String reactedUserID, String commentText)A service that lets the currently logged-in user persist their comment on the database.voidupdateMemoryWithReact(String memoryID, String currentUserID, String reactedUserID)A service that lets the currently logged-in user persist their star on the database.
-
-
-
Method Detail
-
fetchRecentFeed
List<Feed> fetchRecentFeed(String currentUserID) throws InternalServerException, FeedLoadFailedException
A service that lets the currently logged-in user fetch the recent feed for them. The current implementation fetches feeds upload in the last 2 days.- Parameters:
currentUserID- The id of the user currently logged in.- Returns:
- Returns the list of feed for the user.
- Throws:
InternalServerException- Thrown incase there is some internal error.FeedLoadFailedException- Thrown incase the feed for the user couldn't be loaded.
-
updateMemoryWithReact
void updateMemoryWithReact(String memoryID, String currentUserID, String reactedUserID) throws InternalServerException
A service that lets the currently logged-in user persist their star on the database.- Parameters:
memoryID- The id of the memory on which the star/comment has been made.currentUserID- The id of the user making the reaction.reactedUserID- The id of the user on whose memory reaction has been made.- Throws:
InternalServerException- Thrown incase that there is some internal error.
-
updateMemoryWithComment
void updateMemoryWithComment(String memoryID, String currentUserID, String reactedUserID, String commentText) throws InternalServerException
A service that lets the currently logged-in user persist their comment on the database.- Parameters:
memoryID- The id of the memory on which the star/comment has been made.currentUserID- The id of the user making the reaction.reactedUserID- The id of the user on whose memory reaction has been made.commentText- The comment that has been made.- Throws:
InternalServerException- Thrown incase that there is some internal error.
-
-