|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.camel.builder.BuilderSupport org.apache.camel.builder.RouteBuilder org.apache.camel.builder.AdviceWithRouteBuilder
public abstract class AdviceWithRouteBuilder
A RouteBuilder
which has extended capabilities when using
the advice with feature.
RouteDefinition.adviceWith(org.apache.camel.CamelContext, RouteBuilder)
Field Summary |
---|
Fields inherited from class org.apache.camel.builder.RouteBuilder |
---|
log |
Constructor Summary | |
---|---|
AdviceWithRouteBuilder()
|
Method Summary | ||
---|---|---|
List<AdviceWithTask> |
getAdviceWithTasks()
Gets a list of additional tasks to execute after the RouteBuilder.configure() method has been executed
during the advice process. |
|
RouteDefinition |
getOriginalRoute()
Gets the original route we advice. |
|
void |
mockEndpoints()
Mock all endpoints in the route. |
|
void |
mockEndpoints(String... pattern)
Mock all endpoints matching the given pattern. |
|
void |
mockEndpointsAndSkip(String... pattern)
Mock all endpoints matching the given pattern, and skips sending to the original endpoint (detour messages). |
|
void |
replaceFromWith(Endpoint endpoint)
Replaces the route from endpoint with a new endpoint |
|
void |
replaceFromWith(String uri)
Replaces the route from endpoint with a new uri |
|
void |
setOriginalRoute(RouteDefinition originalRoute)
Sets the original route which we advice. |
|
|
weaveAddFirst()
Weaves by adding the nodes to the start of the route. |
|
|
weaveAddLast()
Weaves by adding the nodes to the end of the route. |
|
|
weaveById(String pattern)
Weaves by matching id of the nodes in the route. |
|
|
weaveByToString(String pattern)
Weaves by matching the to string representation of the nodes in the route. |
|
|
weaveByType(Class<T> type)
Weaves by matching type of the nodes in the route. |
Methods inherited from class org.apache.camel.builder.RouteBuilder |
---|
addRoutes, addRoutesToCamelContext, checkInitialized, configure, configureRoute, configureRoutes, createContainer, errorHandler, from, from, from, from, fromF, getContext, getRouteCollection, includeRoutes, intercept, interceptFrom, interceptFrom, interceptSendToEndpoint, onCompletion, onException, onException, populateRoutes, setErrorHandlerBuilder, setRouteCollection, toString |
Methods inherited from class org.apache.camel.builder.BuilderSupport |
---|
bean, bean, bean, bean, body, body, constant, createErrorHandlerBuilder, deadLetterChannel, deadLetterChannel, defaultErrorHandler, endpoint, endpoint, endpoints, endpoints, exceptionMessage, faultBody, faultBodyAs, getErrorHandlerBuilder, header, loggingErrorHandler, loggingErrorHandler, loggingErrorHandler, loggingErrorHandler, method, method, method, method, noErrorHandler, outBody, outBody, property, regexReplaceAll, regexReplaceAll, sendTo, setContext, setContext, simple, simple, systemProperty, systemProperty, xpath |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AdviceWithRouteBuilder()
Method Detail |
---|
public void setOriginalRoute(RouteDefinition originalRoute)
originalRoute
- the original route we advice.public RouteDefinition getOriginalRoute()
public List<AdviceWithTask> getAdviceWithTasks()
RouteBuilder.configure()
method has been executed
during the advice process.
AdviceWithTask
tasks to be executed during the advice process.public void mockEndpoints() throws Exception
Exception
- can be thrown if error occurredpublic void mockEndpoints(String... pattern) throws Exception
pattern
- the pattern(s).
Exception
- can be thrown if error occurredEndpointHelper.matchEndpoint(org.apache.camel.CamelContext, String, String)
public void mockEndpointsAndSkip(String... pattern) throws Exception
pattern
- the pattern(s).
Exception
- can be thrown if error occurredEndpointHelper.matchEndpoint(org.apache.camel.CamelContext, String, String)
public void replaceFromWith(String uri)
uri
- uri of the new endpointpublic void replaceFromWith(Endpoint endpoint)
endpoint
- the new endpointpublic <T extends ProcessorDefinition<?>> AdviceWithBuilder<T> weaveById(String pattern)
EndpointHelper.matchPattern(String, String)
matching algorithm.
pattern
- the pattern
EndpointHelper.matchPattern(String, String)
public <T extends ProcessorDefinition<?>> AdviceWithBuilder<T> weaveByToString(String pattern)
EndpointHelper.matchPattern(String, String)
matching algorithm.
pattern
- the pattern
EndpointHelper.matchPattern(String, String)
public <T extends ProcessorDefinition<?>> AdviceWithBuilder<T> weaveByType(Class<T> type)
type
- the processor type
public <T extends ProcessorDefinition<?>> ProcessorDefinition<?> weaveAddFirst()
public <T extends ProcessorDefinition<?>> ProcessorDefinition<?> weaveAddLast()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |