public interface ProcessorInterceptorProvider
| Modifier and Type | Method and Description |
|---|---|
void |
addInterceptorFactory(org.mule.runtime.api.interception.ProcessorInterceptorFactory interceptorFactory)
Adds an
ProcessorInterceptorFactory to be applied to the components of a flow. |
List<org.mule.runtime.api.interception.ProcessorInterceptorFactory> |
getInterceptorFactories()
Provides the
ProcessorInterceptorFactories that were registered by calling
addInterceptorFactory(ProcessorInterceptorFactory), in the order defined by setInterceptorsOrder(String...)
if defined. |
void |
setInterceptorsOrder(String... packagesOrder)
Determines the order in which the
ProcessorInterceptorFactories products will be applied
to the applicable components. |
void setInterceptorsOrder(String... packagesOrder)
ProcessorInterceptorFactories products will be applied
to the applicable components.
For each factory, its fully qualified class name will be obtained and matched against the
passed packagesOrder to sort the factories. In the case there is more than one factory with a package name prefix, the order in which they were added will be kept.
Assuming this is called with parameters ("org.package", "com.plugin"), and the following
factories have been added through
addInterceptorFactory(ProcessorInterceptorFactory) (in this order):
com.plugin.SomeInterceptororg.mule.MuleInterceptororg.package.logging.LoggerInterceptorcom.plugin.SomeOtherInterceptororg.mule.OtherMuleInterceptorfactories will be sorted, when obtained through getInterceptorFactories()
like this:
org.package.logging.LoggerInterceptorcom.plugin.SomeInterceptorcom.plugin.SomeOtherInterceptororg.mule.MuleInterceptororg.mule.OtherMuleInterceptorpackagesOrder - the wanted order for the interceptors.void addInterceptorFactory(org.mule.runtime.api.interception.ProcessorInterceptorFactory interceptorFactory)
ProcessorInterceptorFactory to be applied to the components of a flow.
By default, the created ProcessorInterceptors will be applied in the same order as they were added by calling this
method. To change this default ordering, setInterceptorsOrder(String...) must be called with the desired order.
interceptorFactory - the factory of ProcessorInterceptors to add.List<org.mule.runtime.api.interception.ProcessorInterceptorFactory> getInterceptorFactories()
ProcessorInterceptorFactories that were registered by calling
addInterceptorFactory(ProcessorInterceptorFactory), in the order defined by setInterceptorsOrder(String...)
if defined.ProcessorInterceptorFactories that will yield the
ProcessorInterceptors to be applied on each component of a flow.Copyright © 2003–2017 MuleSoft, Inc.. All rights reserved.