Interface NewsfeedDetailsView
-
- All Superinterfaces:
EndlessListView,LceView,ListView,MvpLceView,MvpView,RefreshableView
- All Known Implementing Classes:
NewsfeedDetailsActivity
public interface NewsfeedDetailsView extends EndlessListView
TheMvpViewclass forNewsfeedDetailsActivity
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidappendComments(java.util.List<Comment> comments, int totalEntries)Notifies the view to append list ofCommentto the existing comment list.voidclearCommentEditText()Notifies the view to clear the content of Comment Edit Text.voiddeleteComment(int commentId)Notifies the view to delete the comment from the existing list.voiddeletePost()Notifies the view to delete the Post.voidhideRefreshProgress()Notifies the view to hide refresh progress.voidrevertCommentChanges(java.lang.String error, int commentId)Notifies the view to revert any changes made to the comment associated to the post.voidrevertPostChanges(java.lang.String error)Notifies the view to revert any changes made to the post.voidshowErrorDialog(java.lang.String error)Notifies the view to show a dialog with the provided error messagevoidshowNewsDetails(Post post, java.util.List<Comment> comments, int totalEntries, java.util.List<Flag> flag)voidupdateComment(SingleComment comment)Notifies the view to update a comment from the existing list.voidupdatePost(Post post)Notifies the view to update the Post.-
Methods inherited from interface com.cheetahdigital.uikit.widget.list.EndlessListView
onFinishLoadMore, onLoadMoreFailed
-
Methods inherited from interface com.cheetahdigital.uikit.architecture.lce.LceView
onLoadFailed, onLoadSuccess, setErrorViewClickListener
-
Methods inherited from interface com.cheetahdigital.uikit.architecture.lce.MvpLceView
showContent, showError, showLoading
-
Methods inherited from interface com.cheetahdigital.uikit.architecture.refreshable.RefreshableView
onFinishRefresh, onRefreshFailed
-
-
-
-
Method Detail
-
showNewsDetails
void showNewsDetails(Post post, java.util.List<Comment> comments, int totalEntries, java.util.List<Flag> flag)
-
appendComments
void appendComments(java.util.List<Comment> comments, int totalEntries)
Notifies the view to append list ofCommentto the existing comment list. This also means that the GET comments API with pagination was successful- Parameters:
comments- list ofCommentobjecttotalEntries- total number of comments regardless of pagination
-
deleteComment
void deleteComment(int commentId)
Notifies the view to delete the comment from the existing list. This also means that the delete comment API was successful.- Parameters:
commentId- id of comment
-
showErrorDialog
void showErrorDialog(java.lang.String error)
Notifies the view to show a dialog with the provided error message- Parameters:
error- error message
-
deletePost
void deletePost()
Notifies the view to delete the Post. Deleting the post also deletes the comments associated to it. This also means that the delete Post API was successful
-
updateComment
void updateComment(SingleComment comment)
Notifies the view to update a comment from the existing list. This also means that the GET comment API with clearing of response cache was successful- Parameters:
comment- updatedSingleComment
-
hideRefreshProgress
void hideRefreshProgress()
Notifies the view to hide refresh progress. This also means that add comment API failed
-
clearCommentEditText
void clearCommentEditText()
Notifies the view to clear the content of Comment Edit Text. This also means that add comment API was successful
-
updatePost
void updatePost(Post post)
Notifies the view to update the Post. This also means that the GET post API with clearing of cache was successful- Parameters:
post- updatedPost
-
revertPostChanges
void revertPostChanges(java.lang.String error)
Notifies the view to revert any changes made to the post. This also means that Like/Unlike and Flag/Unflag of Post API failed- Parameters:
error- error message
-
revertCommentChanges
void revertCommentChanges(java.lang.String error, int commentId)Notifies the view to revert any changes made to the comment associated to the post. This also means that Like/Unlike and Flag/Unflag of a comment failed- Parameters:
error- error messagecommentId- id of the comment to revert
-
-