com.atlassian.confluence.core.persistence.hibernate
Class VersionedHibernateObjectDao<T extends com.atlassian.core.bean.EntityObject>

java.lang.Object
  extended by org.springframework.dao.support.DaoSupport
      extended by org.springframework.orm.hibernate.support.HibernateDaoSupport
          extended by com.atlassian.hibernate.HibernateObjectDao
              extended by com.atlassian.confluence.core.persistence.hibernate.VersionedHibernateObjectDao<T>
All Implemented Interfaces:
ObjectDao, VersionedObjectDao, org.springframework.beans.factory.InitializingBean
Direct Known Subclasses:
AbstractHibernateAttachmentDao, ConfluenceHibernateObjectDao, ContentEntityObjectHibernateDao, ContentPermissionHibernateDao, GenericHibernateVersionedObjectDao, HibernateSpacePermissionDao

public abstract class VersionedHibernateObjectDao<T extends com.atlassian.core.bean.EntityObject>
extends HibernateObjectDao
implements VersionedObjectDao


Field Summary
protected  com.atlassian.cache.CacheFactory cacheFactory
           
 
Fields inherited from class org.springframework.dao.support.DaoSupport
logger
 
Constructor Summary
VersionedHibernateObjectDao()
           
 
Method Summary
 List<T> findAllSorted(String sortField)
           
 long findLatestVersionsCount()
          Returns the number of results for the latest versions of the current persistent class.
 Iterator<T> findLatestVersionsIterator()
          Returns an iterator for the latest versions of the current persistent class.
 void save(com.atlassian.core.bean.EntityObject objectToSave, com.atlassian.core.bean.EntityObject previousVersion)
           
 void setCacheFactory(com.atlassian.cache.CacheFactory cacheFactory)
           
protected  void updateModificationData(com.atlassian.core.bean.EntityObject objectToSave)
           
 
Methods inherited from class com.atlassian.hibernate.HibernateObjectDao
findAll, findNamedQuery, findNamedQuery, findNamedQuery, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findSingleObject, getByClassId, index, refresh, reIndex, remove, replicate, save, saveRaw, setIndexer, unIndex
 
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, getPersistentClass, refresh, remove, replicate, save, saveRaw
 

Field Detail

cacheFactory

protected com.atlassian.cache.CacheFactory cacheFactory
Constructor Detail

VersionedHibernateObjectDao

public VersionedHibernateObjectDao()
Method Detail

findLatestVersionsIterator

public Iterator<T> findLatestVersionsIterator()
Description copied from interface: VersionedObjectDao
Returns an iterator for the latest versions of the current persistent class.

Specified by:
findLatestVersionsIterator in interface VersionedObjectDao
Returns:
Iterator

findLatestVersionsCount

public long findLatestVersionsCount()
Description copied from interface: VersionedObjectDao
Returns the number of results for the latest versions of the current persistent class.

Specified by:
findLatestVersionsCount in interface VersionedObjectDao
Returns:
a long representing the number of results

findAllSorted

public List<T> findAllSorted(String sortField)
Specified by:
findAllSorted in interface ObjectDao
Overrides:
findAllSorted in class HibernateObjectDao

save

public void save(com.atlassian.core.bean.EntityObject objectToSave,
                 com.atlassian.core.bean.EntityObject previousVersion)
Specified by:
save in interface VersionedObjectDao

updateModificationData

protected void updateModificationData(com.atlassian.core.bean.EntityObject objectToSave)
Overrides:
updateModificationData in class HibernateObjectDao

setCacheFactory

public void setCacheFactory(com.atlassian.cache.CacheFactory cacheFactory)


Confluence is developed by Atlassian.