public interface ObjectDao
Modifier and Type | Field and Description |
---|---|
static boolean |
NON_CACHEABLE
Deprecated.
since 5.8 Use
com.atlassian.hibernate.HibernateObjectDao.Cacheability |
Modifier and Type | Method and Description |
---|---|
List |
findAll()
Find all objects currently persisted of a particular type.
|
List |
findAllSorted(String sortField)
Find all objects currently persisted of a particular type and sort results by named property.
|
List |
findAllSorted(String sortField,
boolean cacheable,
int offset,
int maxResultCount)
Find all objects currently persisted of a particular type and sort results by named property.
|
<T> PageResponse<T> |
findByClassIds(Iterable<Long> ids,
LimitedRequest limitedRequest,
com.google.common.base.Predicate<? super T> filter)
Find a list of objects from the same persistent class.
|
Class |
getPersistentClass() |
void |
refresh(com.atlassian.core.bean.EntityObject objectToRrfresh)
Refreshes the object again with the fresh data from db.
|
void |
remove(com.atlassian.core.bean.EntityObject object)
Remove object from persistence.
|
void |
replicate(Object objectToReplicate)
Replicate the object.
|
void |
save(com.atlassian.core.bean.EntityObject objectToSave) |
void |
saveRaw(com.atlassian.core.bean.EntityObject objectToSave)
saves the object.
|
@Deprecated static final boolean NON_CACHEABLE
com.atlassian.hibernate.HibernateObjectDao.Cacheability
void remove(com.atlassian.core.bean.EntityObject object)
void refresh(com.atlassian.core.bean.EntityObject objectToRrfresh)
void replicate(Object objectToReplicate)
@Nonnull List findAllSorted(String sortField)
sortField
- the name of the property to be sorted on. This should be null if no sorting is required.@Nonnull List findAllSorted(String sortField, boolean cacheable, int offset, int maxResultCount)
sortField
- the name of the property to be sorted on. This should be null if no sorting is required.cacheable
- control whether the results should be cachedoffset
- the index of the first result to be returnedmaxResultCount
- the maximum number of results required. Use -1 to specify no limit.@Nonnull <T> PageResponse<T> findByClassIds(Iterable<Long> ids, LimitedRequest limitedRequest, com.google.common.base.Predicate<? super T> filter)
T
- the type of entity to returnids
- - the ids of the entities to findlimitedRequest
- the pagination request defining the page size to fetchfilter
- a predicate to do in memory filtering of the result set before returningvoid save(com.atlassian.core.bean.EntityObject objectToSave)
Class getPersistentClass()
void saveRaw(com.atlassian.core.bean.EntityObject objectToSave)
objectToSave
- Copyright © 2003–2017 Atlassian. All rights reserved.