Package io.micronaut.coherence.event
Class EventObserverSupport.UnsolicitedCommitEventHandler
- java.lang.Object
-
- io.micronaut.coherence.event.EventObserverSupport.UnsolicitedCommitEventHandler
-
- All Implemented Interfaces:
com.tangosol.net.events.EventDispatcherAwareInterceptor<com.tangosol.net.events.partition.UnsolicitedCommitEvent>
,com.tangosol.net.events.EventInterceptor<com.tangosol.net.events.partition.UnsolicitedCommitEvent>
- Enclosing class:
- EventObserverSupport
public static class EventObserverSupport.UnsolicitedCommitEventHandler extends java.lang.Object
Handler forUnsolicitedCommitEvent
s.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.EnumSet<T>
eventTypes
A set of event types the observer is interested in.protected io.micronaut.coherence.event.ExecutableMethodEventObserver<E,?,?>
observer
The observer method to delegate events to.protected java.lang.String
serviceName
-
Constructor Summary
Constructors Constructor Description UnsolicitedCommitEventHandler(io.micronaut.coherence.event.ExecutableMethodEventObserver<com.tangosol.net.events.partition.UnsolicitedCommitEvent,?,?> observer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.EnumSet<T>
eventTypes()
Create a final set of event types to register this interceptor for.java.lang.String
getScopeName()
Return the name of the scope this interceptor should be registered with.void
introduceEventDispatcher(java.lang.String identifier, com.tangosol.net.events.EventDispatcher dispatcher)
protected boolean
isApplicable(com.tangosol.net.events.EventDispatcher dispatcher, java.lang.String scopeName)
void
onEvent(E event)
protected java.lang.String
removeScope(java.lang.String serviceName)
Remove the scope prefix from a specified service name.
-
-
-
Field Detail
-
serviceName
protected final java.lang.String serviceName
-
observer
protected final io.micronaut.coherence.event.ExecutableMethodEventObserver<E extends com.tangosol.net.events.Event<T>,?,?> observer
The observer method to delegate events to.
-
eventTypes
protected final java.util.EnumSet<T extends java.lang.Enum<T>> eventTypes
A set of event types the observer is interested in.
-
-
Method Detail
-
isApplicable
protected boolean isApplicable(com.tangosol.net.events.EventDispatcher dispatcher, java.lang.String scopeName)
-
introduceEventDispatcher
public void introduceEventDispatcher(java.lang.String identifier, com.tangosol.net.events.EventDispatcher dispatcher)
- Specified by:
introduceEventDispatcher
in interfacecom.tangosol.net.events.EventDispatcherAwareInterceptor<E extends com.tangosol.net.events.Event<T>>
-
onEvent
public void onEvent(E event)
- Specified by:
onEvent
in interfacecom.tangosol.net.events.EventInterceptor<E extends com.tangosol.net.events.Event<T>>
-
eventTypes
protected java.util.EnumSet<T> eventTypes()
Create a final set of event types to register this interceptor for.- Returns:
- a final set of event types to register this interceptor for
-
getScopeName
public java.lang.String getScopeName()
Return the name of the scope this interceptor should be registered with.- Returns:
- the name of the scope this interceptor should be registered with
-
removeScope
protected java.lang.String removeScope(java.lang.String serviceName)
Remove the scope prefix from a specified service name.- Parameters:
serviceName
- the service name to remove scope prefix from- Returns:
- service name with scope prefix removed
-
-