|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.dao.support.DaoSupport
org.springframework.orm.hibernate.support.HibernateDaoSupport
com.atlassian.hibernate.HibernateObjectDao
com.atlassian.confluence.core.persistence.hibernate.VersionedHibernateObjectDao
com.atlassian.confluence.core.persistence.hibernate.ConfluenceHibernateObjectDao
com.atlassian.confluence.pages.persistence.dao.hibernate.HibernateCommentDao
public class HibernateCommentDao
Field Summary |
---|
Fields inherited from class com.atlassian.confluence.core.persistence.hibernate.VersionedHibernateObjectDao |
---|
cacheFactory, confluenceUserDao |
Fields inherited from class org.springframework.dao.support.DaoSupport |
---|
logger |
Fields inherited from interface bucket.core.persistence.ObjectDao |
---|
NON_CACHEABLE |
Constructor Summary | |
---|---|
HibernateCommentDao()
|
Method Summary | |
---|---|
Map<com.atlassian.bonnie.Searchable,Integer> |
countComments(Collection<? extends com.atlassian.bonnie.Searchable> searchables)
Count all comments for each content in a collection |
int |
countComments(com.atlassian.bonnie.Searchable searchable)
Count all comments in a searchable content |
Map<Long,Integer> |
countUnresolvedComments(Collection<Long> containerIds)
Count unresolved comments of comment containers. |
protected Comment |
getByClassId(long id)
Retrieve the object with a particular id from the database. |
Comment |
getById(long id)
Get a comment by its id |
PageResponse<Comment> |
getChildren(Comment comment,
LimitedRequest pageRequest,
Depth depth,
com.google.common.base.Predicate<? super Comment>... predicates)
Get the children of a comment |
List<Comment> |
getPageComments(long pageId,
Date since)
Get the comments that have been added or updated since a specific time |
List<Comment> |
getPageComments(long pageId,
Date since,
String ignoreUsername)
Get the comments that have been added or updated since a specific time but not by a user |
PageResponse<Comment> |
getPageComments(long pageId,
LimitedRequest pageRequest,
Depth depth,
com.google.common.base.Predicate<? super Comment>... predicates)
Get the comments belonging to a page |
Class |
getPersistentClass()
|
Iterator |
getRecentlyUpdatedComments(long spaceId,
int maxResults)
Get all comments that have been updated recently in a space |
Methods inherited from class com.atlassian.confluence.core.persistence.hibernate.VersionedHibernateObjectDao |
---|
findAllSorted, findLatestVersionsCount, findLatestVersionsIterator, findNamedQueryStringParams, save, setCacheFactory, setConfluenceUserDao, updateModificationData |
Methods inherited from class org.springframework.orm.hibernate.support.HibernateDaoSupport |
---|
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory |
Methods inherited from class org.springframework.dao.support.DaoSupport |
---|
afterPropertiesSet, initDao |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface bucket.core.persistence.ObjectDao |
---|
findAll, findAllSorted, findAllSorted, findByClassIds, refresh, remove, replicate, save, saveRaw |
Constructor Detail |
---|
public HibernateCommentDao()
Method Detail |
---|
public Class getPersistentClass()
getPersistentClass
in interface ObjectDao
public Comment getById(long id)
CommentDao
getById
in interface CommentDao
id
- the comment's id
protected Comment getByClassId(long id)
HibernateObjectDao
getByClassId
in class HibernateObjectDao
id
- the id of the object to look up
public Iterator getRecentlyUpdatedComments(long spaceId, int maxResults)
CommentDao
getRecentlyUpdatedComments
in interface CommentDao
spaceId
- the space's idmaxResults
- the maximum number of comments that can be retrieved
Iterator
object that encapsulates the list of comments foundpublic List<Comment> getPageComments(long pageId, Date since)
CommentDao
getPageComments
in interface CommentDao
pageId
- the page's idsince
- Date
the time after which the comments have been added or updated
public List<Comment> getPageComments(long pageId, Date since, String ignoreUsername)
CommentDao
getPageComments
in interface CommentDao
pageId
- the page's idsince
- Date
the time after which the comments have been added or updatedignoreUsername
- the user to be ignored
public Map<com.atlassian.bonnie.Searchable,Integer> countComments(Collection<? extends com.atlassian.bonnie.Searchable> searchables)
CommentDao
countComments
in interface CommentDao
searchables
- a collection of Searchable
objects representing the contents
public int countComments(com.atlassian.bonnie.Searchable searchable)
CommentDao
countComments
in interface CommentDao
searchable
- a Searchable
object representing the content
public PageResponse<Comment> getPageComments(long pageId, LimitedRequest pageRequest, Depth depth, com.google.common.base.Predicate<? super Comment>... predicates)
CommentDao
getPageComments
in interface CommentDao
pageId
- the page's idpageRequest
- the pagination infodepth
- the search depthpredicates
- the predicates used to filter the children
PageResponse
object that encapsulates the commentspublic PageResponse<Comment> getChildren(Comment comment, LimitedRequest pageRequest, Depth depth, com.google.common.base.Predicate<? super Comment>... predicates)
CommentDao
getChildren
in interface CommentDao
comment
- the parent commentpageRequest
- the pagination infodepth
- the search depthpredicates
- the predicates used to filter the children
PageResponse
object that encapsulates the children commentspublic Map<Long,Integer> countUnresolvedComments(@Nonnull Collection<Long> containerIds)
CommentDao
countUnresolvedComments
in interface CommentDao
containerIds
- the list of comment containers ids
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |