Package com.oracle.coherence.cdi
Class CdiMapEventObserver<K,V>
java.lang.Object
com.oracle.coherence.cdi.CdiMapEventObserver<K,V>
- All Implemented Interfaces:
AnnotatedMapListener.MapEventObserver<K,
V>
public class CdiMapEventObserver<K,V>
extends Object
implements AnnotatedMapListener.MapEventObserver<K,V>
An implementation of a
AnnotatedMapListener.MapEventObserver
that wraps a CDI ObserverMethod
that observes MapEvent
.- Author:
- Jonathan Knight 2020.11.20
-
Constructor Summary
ConstructorDescriptionCdiMapEventObserver
(jakarta.enterprise.inject.spi.ObserverMethod<MapEvent<K, V>> method) Create aCdiMapEventObserver
from anObserverMethod
CdiMapEventObserver
(jakarta.enterprise.inject.spi.ProcessObserverMethod<MapEvent<K, V>, ?> event) Create aCdiMapEventObserver
from an observed method event. -
Method Summary
-
Constructor Details
-
CdiMapEventObserver
public CdiMapEventObserver(jakarta.enterprise.inject.spi.ProcessObserverMethod<MapEvent<K, V>, ?> event) Create aCdiMapEventObserver
from an observed method event.- Parameters:
event
- the observed method event
-
CdiMapEventObserver
Create aCdiMapEventObserver
from anObserverMethod
- Parameters:
method
- theObserverMethod
-
-
Method Details
-
notify
Description copied from interface:AnnotatedMapListener.MapEventObserver
Process an event.- Specified by:
notify
in interfaceAnnotatedMapListener.MapEventObserver<K,
V> - Parameters:
event
- the event
-
isAsync
public boolean isAsync()Description copied from interface:AnnotatedMapListener.MapEventObserver
Returntrue
if this observer should be async.- Specified by:
isAsync
in interfaceAnnotatedMapListener.MapEventObserver<K,
V> - Returns:
true
if this observer should be async
-
getObservedQualifiers
Description copied from interface:AnnotatedMapListener.MapEventObserver
Return the qualifiers for the observer that wil be used to further qualify which events are received.- Specified by:
getObservedQualifiers
in interfaceAnnotatedMapListener.MapEventObserver<K,
V> - Returns:
- the qualifiers for the observer
-
toString
-