public interface QueueingSegmentListener<K,V,E extends Event<K,V>> extends IntConsumer
Modifier and Type | Field and Description |
---|---|
static Object |
NOTIFIED |
static Object |
REMOVED |
Modifier and Type | Method and Description |
---|---|
CompletionStage<Void> |
delayProcessing()
Invoked to determine if processing should be delayed or not.
|
Set<CacheEntry<K,V>> |
findCreatedEntries()
This method is to be called just before marking the transfer as complete and after all keys have been manually
processed.
|
boolean |
handleEvent(EventWrapper<K,V,E> wrapper,
ListenerInvocation<Event<K,V>> invocation)
This should be called by any listener when an event is generated to possibly queue it.
|
Object |
markKeyAsProcessing(K key)
This should be invoked on a key before actually processing the data.
|
CompletionStage<Void> |
transferComplete()
This is needed to tell the handler when the complete iteration is done.
|
accept, andThen
Object markKeyAsProcessing(K key)
Set<CacheEntry<K,V>> findCreatedEntries()
CompletionStage<Void> delayProcessing()
CompletableFutures.completedNull()
if processing can continue immediately, otherwise should wait until this
is complete.boolean handleEvent(EventWrapper<K,V,E> wrapper, ListenerInvocation<Event<K,V>> invocation)
wrapper
- The event that was just raisedinvocation
- The invocation the event would be fired onCompletionStage<Void> transferComplete()
Copyright © 2021 JBoss by Red Hat. All rights reserved.