Exemplo n.º 1
0
 public Lock getVariableLock(
     Variable.Finder[] finders, TransactionLockTypes.LockType[] lockTypes) {
   assert finders.length == lockTypes.length;
   VariablesLock lock = new VariablesLock();
   for (int i = 0; i < finders.length; i++) {
     lock.addVariable(finders[i], lockTypes[i]);
   }
   return lock;
 }
Exemplo n.º 2
0
 public Lock getVariableLock(Variable.Finder finder, TransactionLockTypes.LockType lockType) {
   VariablesLock lock = new VariablesLock();
   lock.addVariable(finder, lockType);
   return lock;
 }