public abstract class VersionedHibernateObjectDao<T extends com.atlassian.core.bean.EntityObject> extends HibernateObjectDao implements VersionedObjectDao
HibernateObjectDao.Cacheability
Modifier and Type | Field and Description |
---|---|
protected com.atlassian.cache.CacheFactory |
cacheFactory |
protected ConfluenceUserDao |
confluenceUserDao |
NON_CACHEABLE
Constructor and Description |
---|
VersionedHibernateObjectDao() |
Modifier and Type | Method and Description |
---|---|
List<T> |
findAllSorted(String sortField)
Find all objects currently persisted of a particular type and sort results by named property.
|
long |
findLatestVersionsCount()
Returns the number of results for the latest versions
of the current persistent class.
|
protected long |
findLatestVersionsCount(String... statuses) |
Iterator<T> |
findLatestVersionsIterator()
Returns an iterator for the latest versions of the current
persistent class.
|
protected Iterator<T> |
findLatestVersionsIterator(String... statuses) |
protected List |
findNamedQueryStringParams(String queryName,
boolean cacheable,
LimitedRequest limitedRequest,
Object... paramNamesAndValues)
Deprecated.
since 5.8 Use the equivalent method that uses the
HibernateObjectDao.Cacheability enum instead of the cacheable boolean flag |
protected List |
findNamedQueryStringParams(String queryName,
HibernateObjectDao.Cacheability cacheability,
LimitedRequest limitedRequest,
Object... paramNamesAndValues)
This method here instead of in
HibernateObjectDao in bucket because we don't want to update bucket right now. |
void |
save(com.atlassian.core.bean.EntityObject objectToSave,
com.atlassian.core.bean.EntityObject previousVersion) |
void |
setCacheFactory(com.atlassian.cache.CacheFactory cacheFactory) |
void |
setConfluenceUserDao(ConfluenceUserDao confluenceUserDao) |
protected void |
updateModificationData(com.atlassian.core.bean.EntityObject objectToSave)
Perform any modifications that need to be done to an object every time it is
saved.
|
findAll, findAllSorted, findByClassIds, findNamedQuery, findNamedQuery, findNamedQuery, findNamedQuery, findNamedQuery, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParam, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findNamedQueryStringParams, findSingleObject, getByClassId, getCountResult, index, refresh, reIndex, remove, replicate, save, saveRaw, setIndexer, unIndex, uniqueResult
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
findAll, findAllSorted, findByClassIds, getPersistentClass, refresh, remove, replicate, save, saveRaw
protected com.atlassian.cache.CacheFactory cacheFactory
protected ConfluenceUserDao confluenceUserDao
public Iterator<T> findLatestVersionsIterator()
VersionedObjectDao
findLatestVersionsIterator
in interface VersionedObjectDao
public long findLatestVersionsCount()
VersionedObjectDao
findLatestVersionsCount
in interface VersionedObjectDao
protected long findLatestVersionsCount(String... statuses)
public List<T> findAllSorted(String sortField)
ObjectDao
findAllSorted
in interface ObjectDao
findAllSorted
in class HibernateObjectDao
sortField
- the name of the property to be sorted on. This should be null if no sorting is required.public void save(com.atlassian.core.bean.EntityObject objectToSave, com.atlassian.core.bean.EntityObject previousVersion)
save
in interface VersionedObjectDao
protected void updateModificationData(com.atlassian.core.bean.EntityObject objectToSave)
HibernateObjectDao
updateModificationData
in class HibernateObjectDao
objectToSave
- the object that is about to be saved@Deprecated protected List findNamedQueryStringParams(String queryName, boolean cacheable, LimitedRequest limitedRequest, Object... paramNamesAndValues)
HibernateObjectDao.Cacheability
enum instead of the cacheable boolean flagprotected List findNamedQueryStringParams(String queryName, HibernateObjectDao.Cacheability cacheability, LimitedRequest limitedRequest, Object... paramNamesAndValues)
HibernateObjectDao
in bucket because we don't want to update bucket right now.public void setCacheFactory(com.atlassian.cache.CacheFactory cacheFactory)
public void setConfluenceUserDao(ConfluenceUserDao confluenceUserDao)
Copyright © 2003–2015 Atlassian. All rights reserved.