db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/odmg/locking LockManagerOdmgImpl.java
Date Thu, 18 Nov 2004 23:57:50 GMT
arminw      2004/11/18 15:57:50

  Modified:    src/java/org/apache/ojb/odmg/locking Tag: OJB_1_0_RELEASE
                        LockManagerOdmgImpl.java
  Log:
  bug fix, use Identity objects as key
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.1.2.2   +9 -9      db-ojb/src/java/org/apache/ojb/odmg/locking/LockManagerOdmgImpl.java
  
  Index: LockManagerOdmgImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/locking/LockManagerOdmgImpl.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- LockManagerOdmgImpl.java	18 Sep 2004 13:04:02 -0000	1.1.2.1
  +++ LockManagerOdmgImpl.java	18 Nov 2004 23:57:49 -0000	1.1.2.2
  @@ -1,9 +1,9 @@
   package org.apache.ojb.odmg.locking;
   
  -import org.apache.ojb.odmg.TransactionImpl;
  -import org.apache.ojb.broker.metadata.ClassDescriptor;
   import org.apache.ojb.broker.Identity;
   import org.apache.ojb.broker.core.proxy.ProxyHelper;
  +import org.apache.ojb.broker.metadata.ClassDescriptor;
  +import org.apache.ojb.odmg.TransactionImpl;
   
   /* Copyright 2002-2004 The Apache Software Foundation
    *
  @@ -45,7 +45,7 @@
       public boolean readLock(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.readLock(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.readLock(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   
       public boolean writeLock(TransactionImpl tx, Object obj)
  @@ -57,7 +57,7 @@
       public boolean writeLock(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.writeLock(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.writeLock(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   
       public boolean upgradeLock(TransactionImpl tx, Object obj)
  @@ -69,7 +69,7 @@
       public boolean upgradeLock(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.upgradeLock(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.upgradeLock(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   
       public boolean releaseLock(TransactionImpl tx, Object obj)
  @@ -81,7 +81,7 @@
       public boolean releaseLock(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.releaseLock(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.releaseLock(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   
       public boolean checkRead(TransactionImpl tx, Object obj)
  @@ -93,7 +93,7 @@
       public boolean checkRead(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.checkRead(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.checkRead(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   
       public boolean checkWrite(TransactionImpl tx, Object obj)
  @@ -105,6 +105,6 @@
       public boolean checkWrite(TransactionImpl tx, Identity oid, Object obj)
       {
           ClassDescriptor cld = tx.getBroker().getClassDescriptor(ProxyHelper.getRealClass(obj));
  -        return lm.checkWrite(tx.getGUID(), new Integer(oid.hashCode()), cld.getIsolationLevel());
  +        return lm.checkWrite(tx.getGUID(), oid, cld.getIsolationLevel());
       }
   }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message