public interface JPAExecutor<T>
EntityManager
.
Implementations are executed by the JPAService
.
Modifier and Type | Method and Description |
---|---|
T |
execute(javax.persistence.EntityManager em)
Method that encapsulates JPA access operations.
|
String |
getName()
Return the name of the JPA executor.
|
String getName()
T execute(javax.persistence.EntityManager em) throws JPAExecutorException
Implementations should not close the received EntityManager
.
Implementations should commit any transaction before ending, else the transaction will be rolled back.
em
- an active EntityManager
JPAExecutorException
- thrown if a jpa executor failedCopyright © 2018 Apache Software Foundation. All rights reserved.