| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void | |
| public Element | Returns: the Element visible to the current transactionthe current transaction under which this call is executed currentTransactionId, SoftLockID the soft lock ID softLockId)Get the element the current transaction is supposed to see. |
| public Object | |
| public boolean | Returns: true if the soft lock is orphan and should be cleaned up, false otherwiseCheck if the soft lock expired, ie: that the thread which locked it died |
| public void | |
| public boolean | Returns: true if the soft lock was locked, false otherwisethe time in milliseconds before this method gives up ms)Attempt to lock the soft lock |
| public void | |
| public void |
| clearTryLock | back to summary |
|---|---|
| public void clearTryLock() Clear the state of the soft lock after a tryLock() call succeeded. | |
| freeze | back to summary |
|---|---|
| public void freeze() Freeze the soft lock. A soft lock should only be frozen for a very short period of time as this blocks
the | |
| getElement | back to summary |
|---|---|
| public Element getElement(TransactionID currentTransactionId, SoftLockID softLockId) Get the element the current transaction is supposed to see.
| |
| getKey | back to summary |
|---|---|
| public Object getKey() Get the key of the element this soft lock is guarding
| |
| isExpired | back to summary |
|---|---|
| public boolean isExpired() Check if the soft lock expired, ie: that the thread which locked it died
| |
| lock | back to summary |
|---|---|
| public void lock() Lock the soft lock | |
| tryLock | back to summary |
|---|---|
| public boolean tryLock(long ms) throws InterruptedException Attempt to lock the soft lock
| |
| unfreeze | back to summary |
|---|---|
| public void unfreeze() Unfreeze the soft lock | |
| unlock | back to summary |
|---|---|
| public void unlock() Unlock the soft lock. Once a soft lock got unlocked, it is considered 'dead': it cannot be locked again and must be cleaned up | |