public final class AsynchRouteBuilder extends Object
newInstance(ServiceExtEnum, String, String, AsynchResponseProcessor, DataFormatDefinition)
method,
sets parameters and finally call build(RouteBuilder)
method for creating route definition.Modifier and Type | Method and Description |
---|---|
org.apache.camel.model.RouteDefinition |
build(org.apache.camel.builder.RouteBuilder route)
Builds new route definition for processing incoming asynchronous messages.
|
org.apache.camel.Expression |
getFunnelValue() |
String |
getInUri() |
org.apache.camel.Expression |
getObjectIdExpr() |
String |
getOperation() |
String |
getPolicyRef() |
org.apache.camel.model.DataFormatDefinition |
getResponseMarshalling() |
AsynchResponseProcessor |
getResponseProcessor() |
String |
getRouteId() |
ServiceExtEnum |
getServiceType() |
org.apache.camel.Processor[] |
getValidators() |
static AsynchRouteBuilder |
newInstance(ServiceExtEnum serviceType,
String operation,
String inUri,
AsynchResponseProcessor responseProcessor,
org.apache.camel.model.DataFormatDefinition responseMarshalling)
Creates new instance with basic mandatory parameters.
|
String |
toString() |
AsynchRouteBuilder |
withFunnelValue(org.apache.camel.Expression funnelValue)
Sets funnel value.
|
AsynchRouteBuilder |
withGuaranteedOrder()
Marks the route for processing in guaranteed order by message timestamp.
|
AsynchRouteBuilder |
withGuaranteedOrderWithoutFailed()
Marks the route for processing in guaranteed order by message timestamp.
|
AsynchRouteBuilder |
withObjectIdExpr(org.apache.camel.Expression objectIdExpr)
Sets expression for evaluating object ID.
|
AsynchRouteBuilder |
withPolicyRef(String policyRef)
Sets (Spring bean) reference to policy, e.g.
|
AsynchRouteBuilder |
withResponseProcessor(AsynchResponseProcessor responseProcessor,
org.apache.camel.model.DataFormatDefinition responseMarshalling)
Sets response processor.
|
AsynchRouteBuilder |
withRouteId(String routeId)
Sets route ID.
|
AsynchRouteBuilder |
withValidator(org.apache.camel.Processor... validator)
Sets array of validators, for example
XPathValidator . |
public static AsynchRouteBuilder newInstance(ServiceExtEnum serviceType, String operation, String inUri, AsynchResponseProcessor responseProcessor, org.apache.camel.model.DataFormatDefinition responseMarshalling)
serviceType
- service typeoperation
- operation name with processing routeinUri
- the from URI of this routeresponseProcessor
- the response processorresponseMarshalling
- the response marshallingpublic AsynchRouteBuilder withRouteId(@Nullable String routeId)
AbstractBasicRoute.getInRouteId(ServiceExtEnum, String)
.routeId
- the route IDpublic AsynchRouteBuilder withValidator(@Nullable org.apache.camel.Processor... validator)
XPathValidator
.validator
- the validatorpublic AsynchRouteBuilder withObjectIdExpr(@Nullable org.apache.camel.Expression objectIdExpr)
objectIdExpr
- expression for evaluating object IDMessage.getObjectId()
public AsynchRouteBuilder withFunnelValue(@Nullable org.apache.camel.Expression funnelValue)
funnelValue
- the funnel valueMessage.getFunnelValue()
public AsynchRouteBuilder withGuaranteedOrder()
public AsynchRouteBuilder withGuaranteedOrderWithoutFailed()
public AsynchRouteBuilder withResponseProcessor(AsynchResponseProcessor responseProcessor, org.apache.camel.model.DataFormatDefinition responseMarshalling)
AsynchResponse
will be used.responseProcessor
- the response processorresponseMarshalling
- the response marshallingpublic AsynchRouteBuilder withPolicyRef(@Nullable String policyRef)
policyRef
- the reference to policypublic String getInUri()
public ServiceExtEnum getServiceType()
public String getOperation()
@Nullable public org.apache.camel.Processor[] getValidators()
@Nullable public org.apache.camel.Expression getObjectIdExpr()
@Nullable public org.apache.camel.Expression getFunnelValue()
@Nullable public AsynchResponseProcessor getResponseProcessor()
@Nullable public org.apache.camel.model.DataFormatDefinition getResponseMarshalling()
public final org.apache.camel.model.RouteDefinition build(org.apache.camel.builder.RouteBuilder route)
route
- current route builderCopyright © 2016. All rights reserved.