Overview | Package | Class | Deprecated | Index | Help
| Groovy 1.7.10
| FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.codehaus.groovy.util
[Java] Class LockableObject

    java.lang.Object
      java.util.concurrent.locks.AbstractOwnableSynchronizer
          java.util.concurrent.locks.AbstractQueuedSynchronizer
              org.codehaus.groovy.util.LockableObject

    public class LockableObject
    extends AbstractQueuedSynchronizer

A bit simplified lock designed to be inherited by.

Method Summary
`protected boolean` | `isHeldExclusively()`
`void` | `lock()`
`protected boolean` | `tryAcquire(int acquires)`
`protected boolean` | `tryRelease(int releases)`
`void` | `unlock()`

Methods inherited from 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

Methods inherited from class AbstractOwnableSynchronizer
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll

Methods inherited from class Object
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll

Method Detail

### isHeldExclusively

    protected final boolean isHeldExclusively()

### lock

    public final void lock()

### tryAcquire

    protected final boolean tryAcquire(int acquires)

### tryRelease

    protected final boolean tryRelease(int releases)

### unlock

    public final void unlock()

Copyright © 2003-2010 The Codehaus. All rights reserved.