Class GroupManagerImpl

All Implemented Interfaces:

public class GroupManagerImpl extends Object implements GroupManager
  • Constructor Details

    • GroupManagerImpl

      public GroupManagerImpl(Configuration configuration)
  • Method Details

    • getGroup

      public Object getGroup(Object key)
      Description copied from interface: GroupManager
      Get the group for a given key
      Specified by:
      getGroup in interface GroupManager
      key - the key for which to get the group
      the group, or null if no group is defined for the key
    • collect

      public <K, V> Map<K,V> collect(CacheStream<? extends CacheEntry<K,V>> stream, InvocationContext ctx, String groupName)
      Description copied from interface: GroupManager
      Collects all entries belonging to a single group.

      This method receives a CacheStream and it must filter the CacheEntry that belongs to the group.

      If the cache is transactional, the entries must be stored in the InvocationContext (with proper read version if applicable).

      Specified by:
      collect in interface GroupManager
      Type Parameters:
      K - The key type.
      V - The value type.
      stream - The CacheStream of CacheEntry to filter.
      ctx - The InvocationContext to use during its invocation.
      groupName - The group name to collect.
      A Map with keys and value.