|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectconcurrency.ConcurrencyManager
This class controls the concurrent access to the objects of a semiestructured database.
Constructor Summary | |
ConcurrencyManager(long nextTransactionNumber)
Constructs a new Concurrency Manager with a initial number of transaction. |
Method Summary | |
void |
endTransaction(Transaction transaction)
Removes a transaction from the concurrency manager. |
void |
lock(Transaction transaction,
LockableObject obj,
LockMode lockmode)
Locks a database object. |
void |
lock(Transaction transaction,
LockableObject obj,
LockMode lockmode,
long timeOut)
Locks a database object with a specified time out. |
void |
lockContent(Transaction transaction,
DbStorage.PhysicalID id,
LockMode lockmode)
Locks the content of a datum. |
void |
lockContent(Transaction transaction,
DbStorage.PhysicalID id,
LockMode lockmode,
long timeOut)
Locks the content of a datum with a specified time out. |
void |
lockDictionary(Transaction transaction,
LockMode lockmode)
Locks the dictionary. |
void |
lockDictionary(Transaction transaction,
LockMode lockmode,
long timeOut)
Locks the dictionary with a specified time out. |
void |
lockView(Transaction transaction,
DbStorage.PhysicalID id,
LockMode lockmode)
Locks the view of a datum. |
void |
lockView(Transaction transaction,
DbStorage.PhysicalID id,
LockMode lockmode,
long timeOut)
Locks the view of a datum with a specified time out. |
Transaction |
newTransaction()
Creates and registres a new transaction. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ConcurrencyManager(long nextTransactionNumber)
nextTransactionNumber
- The next number of transaction.Method Detail |
public Transaction newTransaction()
Transaction
object that represents the new transaction.public void endTransaction(Transaction transaction)
transaction
- The transaction to remove.public void lock(Transaction transaction, LockableObject obj, LockMode lockmode) throws NotActiveTransactionException, java.lang.InterruptedException
transaction
- The transaction that locks.obj
- The object to lock.lockmode
- The locking mode.
NotActiveTransactionException
java.lang.InterruptedException
public void lock(Transaction transaction, LockableObject obj, LockMode lockmode, long timeOut) throws NotActiveTransactionException, TimeOutException, java.lang.InterruptedException
transaction
- The transaction that locks.obj
- The object to lock.lockmode
- The locking mode.timeOut
- The time out.
NotActiveTransactionException
TimeOutException
java.lang.InterruptedException
public void lockView(Transaction transaction, DbStorage.PhysicalID id, LockMode lockmode) throws NotActiveTransactionException, java.lang.InterruptedException
transaction
- The transaction that locks.id
- The datum wich view will be locked.lockmode
- The locking mode.
NotActiveTransactionException
java.lang.InterruptedException
public void lockView(Transaction transaction, DbStorage.PhysicalID id, LockMode lockmode, long timeOut) throws NotActiveTransactionException, TimeOutException, java.lang.InterruptedException
transaction
- The transaction that locks.id
- The datum wich view will be locked.lockmode
- The locking mode.timeOut
- The time out.
NotActiveTransactionException
TimeOutException
java.lang.InterruptedException
public void lockContent(Transaction transaction, DbStorage.PhysicalID id, LockMode lockmode) throws NotActiveTransactionException, java.lang.InterruptedException
transaction
- The transaction that locks.id
- The datum wich content will be locked.lockmode
- The locking mode.
NotActiveTransactionException
java.lang.InterruptedException
public void lockContent(Transaction transaction, DbStorage.PhysicalID id, LockMode lockmode, long timeOut) throws NotActiveTransactionException, TimeOutException, java.lang.InterruptedException
transaction
- The transaction that locks.id
- The datum wich content will be locked.lockmode
- The locking mode.timeOut
- The time out.
NotActiveTransactionException
TimeOutException
java.lang.InterruptedException
public void lockDictionary(Transaction transaction, LockMode lockmode) throws NotActiveTransactionException, java.lang.InterruptedException
transaction
- The transaction that locks.lockmode
- The locking mode.
NotActiveTransactionException
java.lang.InterruptedException
public void lockDictionary(Transaction transaction, LockMode lockmode, long timeOut) throws NotActiveTransactionException, TimeOutException, java.lang.InterruptedException
transaction
- The transaction that locks.lockmode
- The locking mode.timeOut
- The time out.
NotActiveTransactionException
TimeOutException
java.lang.InterruptedException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |