Class CommentDAOImpl
java.lang.Object
- All Implemented Interfaces:
org.exoplatform.commons.api.persistence.GenericDAO<Comment,Long>, CommentHandler
-
Field Summary
Fields inherited from class CommonJPADAO
clzFields inherited from class org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl
modelClass -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcountCommentsWithSubs(long taskId) voidvoidvoidorg.exoplatform.commons.utils.ListAccess<Comment> findComments(long taskId) findMentionedUsersOfTask(long taskId) getCommentsSummaries(Collection<Long> taskIds) RunsCOMMENTS_COUNTS_QUERY, thenLATEST_COMMENTS_QUERYfor the authors of the latest comments, keeping for each task the comment created at its latest time, the one created last when several were.getLastComment(long taskId) getSubComments(List<Comment> comments) Methods inherited from class CommonJPADAO
buildCountQuery, buildPath, buildQuery, buildSingleCondition, cloneEntities, cloneEntity, create, find, findEntities, getCacheMethods inherited from class org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl
count, createAll, findAll, getEntityManager, getHibernateDialect, isMSSQLDialect, isOrcaleDialect, update, updateAllMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.exoplatform.commons.api.persistence.GenericDAO
count, create, createAll, find, findAll, update, updateAll
-
Constructor Details
-
CommentDAOImpl
public CommentDAOImpl()
-
-
Method Details
-
delete
-
deleteAll
-
deleteAll
-
findComments
- Specified by:
findCommentsin interfaceCommentHandler
-
getLastComment
- Specified by:
getLastCommentin interfaceCommentHandler- Parameters:
taskId- Task Technical identifier- Returns:
- null if no comments else last created comment on task
-
getSubComments
- Specified by:
getSubCommentsin interfaceCommentHandler
-
findMentionedUsersOfTask
- Specified by:
findMentionedUsersOfTaskin interfaceCommentHandler
-
countCommentsWithSubs
public int countCommentsWithSubs(long taskId) - Specified by:
countCommentsWithSubsin interfaceCommentHandler
-
getCommentsSummaries
RunsCOMMENTS_COUNTS_QUERY, thenLATEST_COMMENTS_QUERYfor the authors of the latest comments, keeping for each task the comment created at its latest time, the one created last when several were.- Specified by:
getCommentsSummariesin interfaceCommentHandler- Parameters:
taskIds- the tasks- Returns:
- the summaries of those that have comments, by task id
-