org.terracotta.toolkit.object
Interface ToolkitLockedObject

All Superinterfaces:
ToolkitObject
All Known Subinterfaces:
ToolkitBlockingQueue<E>, ToolkitList<E>, ToolkitMap<K,V>, ToolkitSet<E>, ToolkitSortedMap<K,V>, ToolkitSortedSet<E>

public interface ToolkitLockedObject
extends ToolkitObject

A ToolkitObject which exposes a ToolkitReadWriteLock. Mutative operations are performed under the write-lock and reads are performed under the read-lock of the ToolkitReadWriteLock


Method Summary
 ToolkitReadWriteLock getReadWriteLock()
          Returns the lock under which mutations are done - can be used to lock externally to execute compound operations.
 
Methods inherited from interface org.terracotta.toolkit.object.ToolkitObject
getName
 

Method Detail

getReadWriteLock

ToolkitReadWriteLock getReadWriteLock()
Returns the lock under which mutations are done - can be used to lock externally to execute compound operations.

NOTE: Calling ToolkitObject.getName() on the returned instance will return null. Same for the ToolkitObject.getName() on the read and write locks from the returned ToolkitReadWriteLock



Copyright © 2014 Terracotta, Inc.. All Rights Reserved.