Class CacheEntriesTask<K,V>
java.lang.Object
org.wildfly.clustering.server.infinispan.scheduler.CacheEntriesTask<K,V>
- Type Parameters:
K- cache key typeV- cache value type
- All Implemented Interfaces:
Consumer<CacheStreamFilter<Map.Entry<K,V>>>, Consumer<CacheStreamFilter<Map.Entry<K, V>>>
public class CacheEntriesTask<K,V>
extends Object
implements Consumer<CacheStreamFilter<Map.Entry<K,V>>>
Invokes a task against cache entries matching a filter.
- Author:
- Paul Ferraro
-
Nested Class Summary
Nested classes/interfaces inherited from interface Consumer
Consumer.ExceptionLogger<E> -
Field Summary
Fields inherited from interface Consumer
EMPTY, EXCEPTION_LOGGER, EXCEPTION_LOGGERS -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(CacheStreamFilter<Map.Entry<K, V>> filter) static <I, K extends Key<I>, V, M>
Consumer<CacheStreamFilter<Map.Entry<K, V>>> cancel(org.infinispan.Cache<K, V> cache, Predicate<Map.Entry<? super K, ? super V>> filter, CacheEntryScheduler<K, V> scheduler) Creates a task that cancels entries matching the specified filter.static <I, K extends Key<I>, V, M>
Consumer<CacheStreamFilter<Map.Entry<K, V>>> schedule(org.infinispan.Cache<K, V> cache, Predicate<Map.Entry<? super K, ? super V>> filter, CacheEntryScheduler<K, V> scheduler) Creates a task that schedules entries matching the specified filter.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Consumer
andThen, compose, compose, handle, thenReturn, when, withDefault, withMonitor
-
Method Details
-
schedule
public static <I, K extends Key<I>, V, M> Consumer<CacheStreamFilter<Map.Entry<K,V>>> schedule(org.infinispan.Cache<K, V> cache, Predicate<Map.Entry<? super K, ? super V>> filter, CacheEntryScheduler<K, V> scheduler) Creates a task that schedules entries matching the specified filter.- Type Parameters:
I- the cache key identifier typeK- the cache key typeV- the cache value typeM- the group member type- Parameters:
cache- an embedded cachefilter- a cache entry filterscheduler- the target scheduler- Returns:
- a task that schedules entries matching the specified filter.
-
cancel
public static <I, K extends Key<I>, V, M> Consumer<CacheStreamFilter<Map.Entry<K,V>>> cancel(org.infinispan.Cache<K, V> cache, Predicate<Map.Entry<? super K, ? super V>> filter, CacheEntryScheduler<K, V> scheduler) Creates a task that cancels entries matching the specified filter.- Type Parameters:
I- the cache key identifier typeK- the cache key typeV- the cache value typeM- the group member type- Parameters:
cache- an embedded cachefilter- a cache entry filterscheduler- the target scheduler- Returns:
- a task that cancels entries matching the specified filter.
-
accept
-