|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.camunda.bpm.cycle.repository.AbstractRepository<T>
public class AbstractRepository<T extends AbstractEntity>
Abstract repository which holds the base information
| Field Summary | |
|---|---|
protected javax.persistence.EntityManager |
em
|
| Constructor Summary | |
|---|---|
protected |
AbstractRepository()
|
| Method Summary | |
|---|---|
long |
countAll()
Returns the number of all entities in the database |
void |
delete(Long id)
Delete a given entity by id |
void |
delete(T entity)
Delete a given entity from |
int |
deleteAll()
Delete all entities BEWARE: It doesn't trigger cascade or removeOrphan functionality for the deleted entites, because it is an JQL statement, not an @{link EntityManager} method. |
List<T> |
findAll()
Find all entities |
T |
findById(long id)
Find a given entity by id |
T |
saveAndFlush(T entity)
Save the given entity and flush |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected javax.persistence.EntityManager em
| Constructor Detail |
|---|
protected AbstractRepository()
| Method Detail |
|---|
@Transactional public T saveAndFlush(T entity)
@Transactional public void delete(Long id)
@Transactional public void delete(T entity)
public T findById(long id)
public List<T> findAll()
public long countAll()
@Transactional public int deleteAll()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||