[Java] Class LockableObject
- org.codehaus.groovy.util.LockableObject
A bit simplified lock designed to be inherited by.
Methods Summary
Type Params | Return Type | Name and description |
---|---|---|
protected boolean |
isHeldExclusively() | |
void |
lock() | |
protected boolean |
tryAcquire(int acquires) | |
protected boolean |
tryRelease(int releases) | |
void |
unlock() |
Inherited Methods Summary
Methods inherited from class | Name |
---|---|
class AbstractQueuedSynchronizer | toString, acquireInterruptibly, getQueueLength, getQueuedThreads, getWaitQueueLength, getWaitingThreads, hasQueuedThreads, hasWaiters, isQueued, release, tryAcquireNanos, acquire, acquireShared, acquireSharedInterruptibly, getExclusiveQueuedThreads, getFirstQueuedThread, getSharedQueuedThreads, hasContended, hasQueuedPredecessors, owns, releaseShared, tryAcquireSharedNanos, wait, wait, wait, equals, hashCode, getClass, notify, notifyAll |
Method Detail
protected final boolean isHeldExclusively()
public final void lock()
protected final boolean tryAcquire(int acquires)
protected final boolean tryRelease(int releases)
public final void unlock()
© 2003-2020 The Apache Software Foundation
Licensed under the Apache license.
https://docs.groovy-lang.org/2.5.14/html/gapi/org/codehaus/groovy/util/LockableObject.html