public void lock ( Object obj , int lockMode ) throws LockNotGrantedException { if ( log . isDebugEnabled ( ) ) log . debug ( "lock object was called on tx " + this + ", object is " + obj . toString ( ) ) ; checkOpen ( ) ; RuntimeObject rtObject = new RuntimeObject ( obj , this ) ; lockAndRegister ( rtObject , lockMode , isImplicitLocking ( ) , getRegistrationList ( ) ) ; // if(isImplicitLocking()) moveToLastInOrderList(rtObject.getIdentity()); }
Upgrade the lock on the given object to the given lock mode . The call has no effect if the object s current lock is already at or above that level of lock mode .