org.apache.openjpa.slice
public class ReentrantSliceLock extends java.util.concurrent.locks.ReentrantLock
Constructor and Description |
---|
ReentrantSliceLock() |
ReentrantSliceLock(boolean fair) |
Modifier and Type | Method and Description |
---|---|
void |
lock()
Locks only for parent thread and let the child use parent's lock.
|
void |
unlock()
Unlocks only if parent thread.
|
getHoldCount, getOwner, getQueuedThreads, getQueueLength, getWaitingThreads, getWaitQueueLength, hasQueuedThread, hasQueuedThreads, hasWaiters, isFair, isHeldByCurrentThread, isLocked, lockInterruptibly, newCondition, toString, tryLock, tryLock
public ReentrantSliceLock()
public ReentrantSliceLock(boolean fair)
public void lock()
lock
in interface java.util.concurrent.locks.Lock
lock
in class java.util.concurrent.locks.ReentrantLock
public void unlock()
unlock
in interface java.util.concurrent.locks.Lock
unlock
in class java.util.concurrent.locks.ReentrantLock