@PermitAll public class LockServiceBean extends com.whitestein.lsps.common.SecureAndLoggingService implements LockServiceLocal, LockServiceRemote
| Constructor and Description |
|---|
LockServiceBean()
Creates new instance.
|
LockServiceBean(LockDao lockDao)
Creates new instance.
|
| Modifier and Type | Method and Description |
|---|---|
Lock |
acquireLock(java.lang.String lockName,
java.lang.String message)
Acquires lock with the given lock name.
|
boolean |
isLocked(java.lang.String lockName)
Returns true if a lock with the given lock name is held .
|
void |
releaseLock(java.lang.String lockName)
Release lock with the given lock name.
|
public LockServiceBean()
public LockServiceBean(LockDao lockDao)
lockDao - the lock daojava.lang.NullPointerException - if lockDao is null@RightsAllowed(value="Lock:Manage") public Lock acquireLock(java.lang.String lockName, java.lang.String message)
LockServicenull, otherwise it returns Lock that holds the locks.acquireLock in interface LockServicemessage - arbitrary message, cannot be nullnull if requested lock was acquired@RightsAllowed(value="Lock:Manage") public void releaseLock(java.lang.String lockName)
LockServicereleaseLock in interface LockService@RightsAllowed(value="Lock:Manage") public boolean isLocked(java.lang.String lockName)
LockServiceisLocked in interface LockServiceCopyright © 2007-2020 Whitestein Technologies. All Rights Reserved.