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
com.atlassian.hibernate.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)
Deprecated.
since 5.10. Subclasses should implement this themselves.
|
void |
setConfluenceUserDao(ConfluenceUserDao confluenceUserDao)
Deprecated.
since 5.10. Subclasses should implement this themselves.
|
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.
|
applyTransactionTimeout, applyTransactionTimeout, checkDaoConfig, createHibernateTemplate, 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, getHibernateTemplate, getSession, getSessionFactory, index, refresh, reIndex, remove, replicate, save, saveRaw, setHibernateTemplate, setIndexer, setSessionFactory, unIndex, uniqueResult
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)
@Nonnull 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)
com.atlassian.hibernate.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.@Deprecated public void setCacheFactory(com.atlassian.cache.CacheFactory cacheFactory)
@Deprecated public void setConfluenceUserDao(ConfluenceUserDao confluenceUserDao)
Copyright © 2003–2017 Atlassian. All rights reserved.