public final class LockManagerImpl extends Object implements LockManager
LockManager.LockableItem, LockManager.LockContext, LockManager.Method| Constructor and Description |
|---|
LockManagerImpl() |
| Modifier and Type | Method and Description |
|---|---|
LockManager.LockContext |
getCurrentLockContext()
Get the lock context associated with the current thread.
|
<T extends LockManager.LockableItem> |
getItemForType(Class<T> type) |
LockManager.LockContext |
lockItems(LockManager.Method method,
LockManager.LockableItem... items)
Lock the number of given items
|
LockManager.LockContext |
lockItems(LockManager.Method method,
long timeout,
TimeUnit unit,
LockManager.LockableItem... items)
Lock the number of given items with timeout
|
void |
unlockItems(LockManager.LockContext context)
Unlock the context
|
public <T extends LockManager.LockableItem> T getItemForType(Class<T> type)
getItemForType in interface LockManagerpublic LockManager.LockContext getCurrentLockContext()
LockManagergetCurrentLockContext in interface LockManagerpublic LockManager.LockContext lockItems(LockManager.Method method, LockManager.LockableItem... items)
LockManagerlockItems in interface LockManagerpublic LockManager.LockContext lockItems(LockManager.Method method, long timeout, TimeUnit unit, LockManager.LockableItem... items)
LockManagerlockItems in interface LockManagerpublic void unlockItems(LockManager.LockContext context)
LockManagerunlockItems in interface LockManagerCopyright © 2013 JBoss by Red Hat. All rights reserved.