public interface LockingService
| Modifier and Type | Method and Description |
|---|---|
boolean |
isLockOwner(Object entityId,
Principal principal)
Return true if the given principal holds the lock for the given entity.
|
boolean |
lock(Object entityId,
Principal principal)
Locks the given entity for the given principal.
|
Principal |
lockOwner(Object entityId)
Returns the lock owner, or null if not locked
|
boolean |
unlock(Object entityId,
Principal principal)
Unlocks the given entity for the current principal.
|
boolean lock(Object entityId, Principal principal)
entityId - the entity to lockprincipal - the lock ownerboolean unlock(Object entityId, Principal principal)
entityId - the entity to unlockprincipal - the lock ownerboolean isLockOwner(Object entityId, Principal principal)
entityId - the entity with the lockprincipal - the principalCopyright © 2021 Paul Warren. All rights reserved.