Interface Lockable
-
- All Known Subinterfaces:
Counter
,DistributedDataStructure
,DistributedHashSet<T>
,DistributedList<T>
,DistributedMap<K,V>
,DistributedQueue<T>
public interface Lockable
This interface contains methods and parameters required for locking data structures.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
lock(TimeSpan timeout)
Acquire a lock on an collection in cache.void
unlock()
Unlock a locked collection
-
-
-
Method Detail
-
lock
boolean lock(TimeSpan timeout)
Acquire a lock on an collection in cache.- Parameters:
timeout
- The timeout after which lock will be automatically released.- Returns:
- True if lock was acquired successfully;otherwise false.
-
unlock
void unlock()
Unlock a locked collection
-
-