Skip navigation links

Oracle® Fusion Middleware Java API Reference for Oracle Coherence
12c (12.1.3.0.0)

E47890-01


com.tangosol.net.events
Interface InterceptorRegistry


public interface InterceptorRegistry

An InterceptorRegistry manages the registration of EventInterceptors and facilitates the introduction of EventInterceptors to EventDispatchers.

Registering an EventInterceptor will cause it to be introduced to all currently registered and future EventDispatchers. EventInterceptors can assume responsibility for determining whether or not to bind to each EventDispatcher by implementing EventDispatcherAwareInterceptor.introduceEventDispatcher(java.lang.String, com.tangosol.net.events.EventDispatcher).

The semantics of how to act upon discovering a duplicate interceptor, based on identifier, can be prescribed via the RegistrationBehavior enum.

Since:
Coherence 12.1.2
Author:
rhan, nsa, mwj, rhl, hr 2011.03.29

Method Summary
 EventInterceptor getEventInterceptor(java.lang.String sIdentifier)
          Return a registered EventInterceptor.
 java.lang.String registerEventInterceptor(EventInterceptor interceptor)
          Register an EventInterceptor uniquely identified based on the presence of an annotation or default to the fully qualified class name.
 java.lang.String registerEventInterceptor(EventInterceptor interceptor, RegistrationBehavior behavior)
          Register an EventInterceptor uniquely identified based on the presence of an annotation or default to the fully qualified class name.
 java.lang.String registerEventInterceptor(java.lang.String sIdentifier, EventInterceptor interceptor, RegistrationBehavior behavior)
          Register a uniquely identified EventInterceptor.
 void unregisterEventInterceptor(java.lang.String sIdentifier)
          Unregister an EventInterceptor, and remove it from all EventDispatchers.

 

Method Detail

registerEventInterceptor

java.lang.String registerEventInterceptor(EventInterceptor interceptor)
Register an EventInterceptor uniquely identified based on the presence of an annotation or default to the fully qualified class name. The EventInterceptor will be introduced to all current and future EventDispatchers.
Parameters:
interceptor - the EventInterceptor to register
Returns:
a string identifier used to register the interceptor
Throws:
java.lang.IllegalArgumentException - if an EventInterceptor with the same identifier is already registered

registerEventInterceptor

java.lang.String registerEventInterceptor(EventInterceptor interceptor,
                                          RegistrationBehavior behavior)
Register an EventInterceptor uniquely identified based on the presence of an annotation or default to the fully qualified class name. The RegistrationBehavior specifies how to act upon registering a duplicate interceptor. The EventInterceptor will be introduced to all current and future EventDispatchers.
Parameters:
interceptor - the EventInterceptor to register
behavior - the behavior enacted upon discovering duplicate interceptors
Returns:
a string identifier used to register the interceptor
Throws:
java.lang.IllegalArgumentException - if an EventInterceptor with the same identifier is already registered

registerEventInterceptor

java.lang.String registerEventInterceptor(java.lang.String sIdentifier,
                                          EventInterceptor interceptor,
                                          RegistrationBehavior behavior)
Register a uniquely identified EventInterceptor. The EventInterceptor will be introduced to all current and future EventDispatchers.
Parameters:
sIdentifier - the unique name identifying the EventInterceptor
interceptor - the EventInterceptor to register
behavior - the behavior enacted upon discovering duplicate interceptors
Throws:
java.lang.IllegalArgumentException - if an EventInterceptor with the same identifier is already registered

unregisterEventInterceptor

void unregisterEventInterceptor(java.lang.String sIdentifier)
Unregister an EventInterceptor, and remove it from all EventDispatchers.
Parameters:
sIdentifier - the unique identifier of the interceptor to unregister

getEventInterceptor

EventInterceptor getEventInterceptor(java.lang.String sIdentifier)
Return a registered EventInterceptor.
Returns:
sIdentifier the unique identifier of the interceptor

Skip navigation links

Oracle® Fusion Middleware Java API Reference for Oracle Coherence
12c (12.1.3.0.0)

E47890-01


Copyright © 2000, 2014, Oracle and/or its affiliates. All rights reserved.