Package org.geotools.data.directory
Class DirectoryLockingManager
- Object
-
- DirectoryLockingManager
-
- All Implemented Interfaces:
LockingManager
public class DirectoryLockingManager extends Object implements LockingManager
Locking manager that will delegate its work to the locking managers of the delegate data stores- Author:
- Andrea Aime - OpenGeo
-
-
Constructor Summary
Constructors Constructor Description DirectoryLockingManager(DirectoryTypeCache cache)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanexists(String authID)Check if any locks exist held by the authorizationlockID.voidlockFeatureID(String typeName, String authID, Transaction transaction, FeatureLock featureLock)FeatureID based locking.booleanrefresh(String authID, Transaction transaction)Refresh locks held by the authorizationlockID.booleanrelease(String authID, Transaction transaction)Release locks held by the authorizationlockID.voidunLockFeatureID(String typeName, String authID, Transaction transaction, FeatureLock featureLock)FeatureID based unlocking.
-
-
-
Method Detail
-
exists
public boolean exists(String authID)
Description copied from interface:LockingManagerCheck if any locks exist held by the authorizationlockID.(remember that the lock may have expired)
- Specified by:
existsin interfaceLockingManager- Parameters:
authID- Authorization for lock- Returns:
trueif lock was found
-
release
public boolean release(String authID, Transaction transaction) throws IOException
Description copied from interface:LockingManagerRelease locks held by the authorizationlockID.(remember that the lock may have expired)
- Specified by:
releasein interfaceLockingManager- Parameters:
authID- Authorization for locktransaction- Transaction with authorization for lockID- Returns:
trueif lock was found and released- Throws:
IOException
-
refresh
public boolean refresh(String authID, Transaction transaction) throws IOException
Description copied from interface:LockingManagerRefresh locks held by the authorizationlockID.All features locked with the provied
lockIDwill be locked for additional time (the origional duration requested).(remember that the lock may have expired)
- Specified by:
refreshin interfaceLockingManager- Parameters:
authID- Authorization for locktransaction- Transaction with authorization for lockID- Returns:
trueif lock was found and refreshed- Throws:
IOException
-
unLockFeatureID
public void unLockFeatureID(String typeName, String authID, Transaction transaction, FeatureLock featureLock) throws IOException
Description copied from interface:LockingManagerFeatureID based unlocking.- Specified by:
unLockFeatureIDin interfaceLockingManager- Throws:
IOException
-
lockFeatureID
public void lockFeatureID(String typeName, String authID, Transaction transaction, FeatureLock featureLock) throws IOException
Description copied from interface:LockingManagerFeatureID based locking.- Specified by:
lockFeatureIDin interfaceLockingManager- Throws:
IOException
-
-