Package org.apache.camel.spi
Interface CamelInternalProcessorAdvice<T>
- Type Parameters:
T
-
public interface CamelInternalProcessorAdvice<T>
An advice (before and after) to execute cross-cutting functionality in the Camel routing engine.
The Camel routing engine will execute the
before(org.apache.camel.Exchange)
and
after(org.apache.camel.Exchange, Object)
methods during routing in correct order.- See Also:
-
org.apache.camel.impl.engine.CamelInternalProcessor
-
Method Summary
-
Method Details
-
before
Callback executed before processing a step in the route.- Parameters:
exchange
- the current exchange- Returns:
- any state to keep and provide as data to the
after(org.apache.camel.Exchange, Object)
method, or use null for no state. - Throws:
Exception
- is thrown if error during the call.
-
after
Callback executed after processing a step in the route.- Parameters:
exchange
- the current exchangedata
- the state, if any, returned in thebefore(org.apache.camel.Exchange)
method.- Throws:
Exception
- is thrown if error during the call.
-
hasState
default boolean hasState()Whether this advice has state or not.
-