|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface declares the functionality of the OJB internal Locking mechanism. A default implementaion LockManagerDefaultImpl is provided. This implementaion keeps distributed locks in the database. The locking mechanisms thus involves a lot of database lookups and writes. For some environments this solution may not be adequate. OJB allows to provide user defined implementations of this interface. To activate a user defined LockManagerDefaultImpl it must be configured in the OJB.properties file.
Method Summary | |
boolean |
checkRead(TransactionImpl tx,
java.lang.Object obj)
checks if there is a readlock for transaction tx on object obj. |
boolean |
checkWrite(TransactionImpl tx,
java.lang.Object obj)
checks if there is a writelock for transaction tx on object obj. |
boolean |
readLock(TransactionImpl tx,
java.lang.Object obj)
aquires a readlock for transaction tx on object obj. |
boolean |
releaseLock(TransactionImpl tx,
java.lang.Object obj)
releases a lock for transaction tx on object obj. |
boolean |
upgradeLock(TransactionImpl tx,
java.lang.Object obj)
upgrades readlock for transaction tx on object obj to a writelock. |
boolean |
writeLock(TransactionImpl tx,
java.lang.Object obj)
aquires a writelock for transaction tx on object obj. |
Method Detail |
public boolean readLock(TransactionImpl tx, java.lang.Object obj)
public boolean writeLock(TransactionImpl tx, java.lang.Object obj)
public boolean upgradeLock(TransactionImpl tx, java.lang.Object obj)
public boolean releaseLock(TransactionImpl tx, java.lang.Object obj)
public boolean checkRead(TransactionImpl tx, java.lang.Object obj)
public boolean checkWrite(TransactionImpl tx, java.lang.Object obj)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |