Class WrapperCollections.ConcurrentWrapperMap<K,V>

java.lang.Object
com.tangosol.util.WrapperCollections.ConcurrentWrapperMap<K,V>
All Implemented Interfaces:
ConcurrentMap<K,V>, Map<K,V>
Enclosing class:
WrapperCollections

public static class WrapperCollections.ConcurrentWrapperMap<K,V> extends Object implements ConcurrentMap<K,V>
Map implementation which uses a ReadWriteLock to manage concurrent access to an underlying Map.
Since:
Coherence 3.7
  • Field Details

    • m_mapDelegate

      protected Map<K,V> m_mapDelegate
      The Map to which this wrapper delegates.
    • m_lock

      protected final ReadWriteLock m_lock
      The read/write lock for concurrency control.
    • m_lockShared

      protected final Lock m_lockShared
      The shared lock for performing read operations.
    • m_lockExclusive

      protected final Lock m_lockExclusive
      The exclusive lock for performing read/write operations.
    • m_setKeys

      protected Set<K> m_setKeys
      The key set.
    • m_setEntries

      protected Set<Map.Entry<K,V>> m_setEntries
      The entry set.
    • m_collValues

      protected Collection<V> m_collValues
      The values collection.
    • m_fStrict

      protected final boolean m_fStrict
      Determines whether or not all of the Entry methods are protected; if set to true, then all Entry methods are protected.
  • Constructor Details

    • ConcurrentWrapperMap

      protected ConcurrentWrapperMap()
    • ConcurrentWrapperMap

      public ConcurrentWrapperMap(Map<K,V> map)
      Create an ConcurrentWrapperMap which delegates to the specified Map.
      Parameters:
      map - the Map to delegate all calls to
    • ConcurrentWrapperMap

      protected ConcurrentWrapperMap(Map<K,V> map, ReadWriteLock lock)
      Create an ConcurrentWrapperMap which delegates to the specified Map.
      Parameters:
      map - the Map to delegate all calls to
      lock - a read/write lock for concurrency management
    • ConcurrentWrapperMap

      protected ConcurrentWrapperMap(Map<K,V> map, ReadWriteLock lock, boolean fStrict)
      Create an ConcurrentWrapperMap which delegates to the specified Map.
      Parameters:
      map - the Map to delegate all calls to
      lock - a read/write lock for concurrency management
      fStrict - pass true to protect all Entry methods; false to protect only the setValue() method
  • Method Details