|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SessionsRepository
Interface implemented by the object returned by
HibernateTransactionService.getCurrentTransaction
.
Used by SessionProxy
s to access a Session
by its id.
Generally used internally only.
Method Summary | |
---|---|
void |
endAllSessions(boolean close,
boolean commit)
Terminate all sessions enlisted in the current transaction. |
org.hibernate.classic.Session |
getSession(java.lang.String id,
org.hibernate.SessionFactory factory)
Get a Session by its id for the current
transaction (in the current thread). |
Method Detail |
---|
org.hibernate.classic.Session getSession(java.lang.String id, org.hibernate.SessionFactory factory)
Session
by its id
for the current
transaction (in the current thread).
If this session does not exist yet then it is created by the
underlying SessionFactory
and it is "enlisted" into the
current transaction.
id
- unique identifier of the Sessionfactory
- SessionFactory to be used to create new Session if needed
id
and the current
transactionvoid endAllSessions(boolean close, boolean commit)
HibernateTransactionService
.
close
- true
if sessions should be closed immediately
or notcommit
- true
if all sessions should be committed
before closing, false
if they should be rolled back
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |