public class OwnableReentrantPerEntryLockContainer extends AbstractPerEntryLockContainer<OwnableRefCountingReentrantLock>
locks| Constructor and Description |
|---|
OwnableReentrantPerEntryLockContainer(int concurrencyLevel) |
| Modifier and Type | Method and Description |
|---|---|
protected Log |
getLog() |
boolean |
isLocked(Object key) |
protected void |
lock(OwnableRefCountingReentrantLock lock,
Object lockOwner) |
protected OwnableRefCountingReentrantLock |
newLock() |
boolean |
ownsLock(Object key,
Object owner)
Tests if a give owner owns a lock on a specified object.
|
protected boolean |
tryLock(OwnableRefCountingReentrantLock lock,
long timeout,
TimeUnit unit,
Object lockOwner) |
protected void |
unlock(OwnableRefCountingReentrantLock l,
Object owner) |
acquireLock, getLock, getLockId, getNumLocksHeld, releaseLock, size, toStringsafeReleasepublic OwnableReentrantPerEntryLockContainer(int concurrencyLevel)
protected Log getLog()
getLog in class AbstractLockContainer<OwnableRefCountingReentrantLock>protected OwnableRefCountingReentrantLock newLock()
newLock in class AbstractPerEntryLockContainer<OwnableRefCountingReentrantLock>public boolean ownsLock(Object key, Object owner)
LockContainerkey - object to checkowner - owner to testpublic boolean isLocked(Object key)
key - objectprotected boolean tryLock(OwnableRefCountingReentrantLock lock, long timeout, TimeUnit unit, Object lockOwner) throws InterruptedException
tryLock in class AbstractLockContainer<OwnableRefCountingReentrantLock>InterruptedExceptionprotected void lock(OwnableRefCountingReentrantLock lock, Object lockOwner)
lock in class AbstractLockContainer<OwnableRefCountingReentrantLock>protected void unlock(OwnableRefCountingReentrantLock l, Object owner)
unlock in class AbstractLockContainer<OwnableRefCountingReentrantLock>Copyright © 2016 JBoss, a division of Red Hat. All rights reserved.