org.drools.guvnor.server.util
Class AssetLockManager
java.lang.Object
org.drools.guvnor.server.util.AssetLockManager
@Scope(value=APPLICATION)
@Startup
@Name(value="assetLockManager")
public class AssetLockManager
- extends Object
Manages the locks for assets.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AssetLockManager
public AssetLockManager()
instance
public static AssetLockManager instance()
isAssetLocked
public boolean isAssetLocked(String uuid)
getAssetLockerUserName
public String getAssetLockerUserName(String uuid)
- Return the lockers user name.
- Parameters:
uuid
- Id of the asset.
- Returns:
- Lockers user name or null if there is no lock with this uuid.
lockAsset
public void lockAsset(String uuid,
String userName)
- Locks the asset, if a lock already exists this over writes it.
- Parameters:
uuid
- Id of the asset.userName
- User name of the user that is locking the asset.
unLockAsset
public void unLockAsset(String uuid)
Copyright © 2001-2011 JBoss Inc.. All Rights Reserved.