org.eclipse.swordfish.internal.core.planner
Class CoreFilterStrategy

java.lang.Object
  extended by org.eclipse.swordfish.internal.core.planner.CoreFilterStrategy
All Implemented Interfaces:
FilterStrategy, Strategy

public class CoreFilterStrategy
extends java.lang.Object
implements FilterStrategy

CoreFilterStrategy takes care that all mandatory core interceptors are present in the interceptor chain.


Field Summary
static java.lang.String CORE_INTERCEPTOR_NAMESPACE
           
 
Constructor Summary
CoreFilterStrategy()
           
 
Method Summary
 java.util.List<Interceptor> filter(java.util.List<Interceptor> interceptors, ReadOnlyRegistry<Interceptor> registry, java.util.List<Hint<?>> hints)
          Create and return an interceptor chain with the interceptors which shall process subsequent message exchanges.
 int getPriority()
          Indicates the ordering if several unified strategies can be applied.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CORE_INTERCEPTOR_NAMESPACE

public static final java.lang.String CORE_INTERCEPTOR_NAMESPACE
See Also:
Constant Field Values
Constructor Detail

CoreFilterStrategy

public CoreFilterStrategy()
Method Detail

filter

public java.util.List<Interceptor> filter(java.util.List<Interceptor> interceptors,
                                          ReadOnlyRegistry<Interceptor> registry,
                                          java.util.List<Hint<?>> hints)
Create and return an interceptor chain with the interceptors which shall process subsequent message exchanges. The following rules apply for filtering:

Specified by:
filter in interface FilterStrategy
Parameters:
interceptors - - the interceptor chain to be filtered. This original List will not be modified.
registry - - the interceptor registry containing property data for the interceptors of the chain using the corresponding interceptor instance as key. The properties are merged by Swordfish from the properties returned by the getProperties() method of the interceptor, the property dictionary provided at OSGI service registration, and the Swordfish configuration. Values from the Swordfish configuration have precedence over those provided at OSGI service registration. Hard-coded properties from the getProperties() method have lowest precedence.
hints - - If a HintExtractor has been registered, the List of Hints extracted from the current message exchange is provided in this argument. Otherwise, it is null.
Returns:
the filtered interceptor chain (must not be null).

getPriority

public int getPriority()
Description copied from interface: Strategy
Indicates the ordering if several unified strategies can be applied.

Specified by:
getPriority in interface Strategy