Home » openjdk-7 » java » util » concurrent » locks » [javadoc | source]
java.util.concurrent.locks
abstract static class: ReentrantLock.Sync [javadoc | source]
java.lang.Object
   java.util.concurrent.locks.AbstractOwnableSynchronizer
      java.util.concurrent.locks.AbstractQueuedSynchronizer
         java.util.concurrent.locks.ReentrantLock$Sync

All Implemented Interfaces:
    Serializable

Direct Known Subclasses:
    FairSync, NonfairSync

Base of synchronization control for this lock. Subclassed into fair and nonfair versions below. Uses AQS state to represent the number of holds on the lock.
Fields inherited from java.util.concurrent.locks.AbstractQueuedSynchronizer:
spinForTimeoutThreshold
Method from java.util.concurrent.locks.ReentrantLock$Sync Summary:
getHoldCount,   getOwner,   isHeldExclusively,   isLocked,   lock,   newCondition,   nonfairTryAcquire,   tryRelease
Methods from java.util.concurrent.locks.AbstractQueuedSynchronizer:
acquire,   acquireInterruptibly,   acquireQueued,   acquireShared,   acquireSharedInterruptibly,   apparentlyFirstQueuedIsExclusive,   compareAndSetState,   fullyRelease,   getExclusiveQueuedThreads,   getFirstQueuedThread,   getQueueLength,   getQueuedThreads,   getSharedQueuedThreads,   getState,   getWaitQueueLength,   getWaitingThreads,   hasContended,   hasQueuedPredecessors,   hasQueuedThreads,   hasWaiters,   isHeldExclusively,   isOnSyncQueue,   isQueued,   owns,   release,   releaseShared,   setState,   toString,   transferAfterCancelledWait,   transferForSignal,   tryAcquire,   tryAcquireNanos,   tryAcquireShared,   tryAcquireSharedNanos,   tryRelease,   tryReleaseShared
Methods from java.util.concurrent.locks.AbstractOwnableSynchronizer:
getExclusiveOwnerThread,   setExclusiveOwnerThread
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.util.concurrent.locks.ReentrantLock$Sync Detail:
 final int getHoldCount() 
 final Thread getOwner() 
 protected final boolean isHeldExclusively() 
 final boolean isLocked() 
 abstract  void lock()
    Performs Lock#lock . The main reason for subclassing is to allow fast path for nonfair version.
 final ConditionObject newCondition() 
 final boolean nonfairTryAcquire(int acquires) 
    Performs non-fair tryLock. tryAcquire is implemented in subclasses, but both need nonfair try for trylock method.
 protected final boolean tryRelease(int releases)