Author: smarlow(a)redhat.com
Date: 2009-11-24 19:05:08 -0500 (Tue, 24 Nov 2009)
New Revision: 18054
Modified:
core/trunk/core/src/main/java/org/hibernate/Session.java
Log:
HHH-4546 add JPA 2.0 locking. Javadoc change.
Modified: core/trunk/core/src/main/java/org/hibernate/Session.java
===================================================================
--- core/trunk/core/src/main/java/org/hibernate/Session.java 2009-11-24 23:59:50 UTC (rev
18053)
+++ core/trunk/core/src/main/java/org/hibernate/Session.java 2009-11-25 00:05:08 UTC (rev
18054)
@@ -552,8 +552,9 @@
public void lock(String entityName, Object object, LockMode lockMode) throws
HibernateException;
/**
- * Build a lockRequest that specifies the LockMode, pessimistic lock timeout and lock
scope.
- * timeout and scope is ignored for optimistic locking.
+ * Build a LockRequest that specifies the LockMode, pessimistic lock timeout and lock
scope.
+ * timeout and scope is ignored for optimistic locking. After building the
LockRequest,
+ * call LockRequest.lock to perform the requested locking.
*
* Use: session.buildLockRequest().
* setLockMode(LockMode.PESSIMISTIC_WRITE).setTimeOut(1000 * 60).lock(entity);
Show replies by date