public class Lockable
extends java.lang.Object
Constructor and Description |
---|
Lockable() |
Modifier and Type | Method and Description |
---|---|
boolean |
isLocked() |
void |
lock() |
void |
releaseLock(boolean fullRelease)
Releases the lock owned by the current thread
|
public void lock()
public void releaseLock(boolean fullRelease)
fullRelease
- - if true, this will release all locks the thread has called on this instance, if false, it will unlock the last call to this
instance, if the last call is the last lock to release then this instance is unlocked.public boolean isLocked()