public interface UnitOfWork
Session
, EntityManager
or ObjectContainer
respectively.
The Unit of Work referred to by UnitOfWork will always be local to the calling thread. Be careful to end() in a finally block. Neither JPA, nor Hibernate supports threadsafe sessions (reasoning behind thread-locality of Unit of Work semantics).
Modifier and Type | Method and Description |
---|---|
void |
begin()
Starts a Unit Of Work.
|
void |
end()
Declares an end to the current Unit of Work.
|
void begin()
void end()
Transaction semantics are not affected.
Copyright © 2006-2016 Google, Inc.. All Rights Reserved.