|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.camel.model.OptionalIdentifiedDefinition<Type> org.apache.camel.model.ProcessorDefinition<Type> org.apache.camel.model.NoOutputDefinition<WireTapDefinition<Type>> org.apache.camel.model.WireTapDefinition<Type>
public class WireTapDefinition<Type extends ProcessorDefinition<Type>>
Represents an XML <wireTap/> element
Field Summary | |
---|---|
protected Endpoint |
endpoint
|
protected String |
ref
|
protected String |
uri
|
Fields inherited from class org.apache.camel.model.ProcessorDefinition |
---|
inheritErrorHandler, log |
Constructor Summary | |
---|---|
WireTapDefinition()
|
|
WireTapDefinition(Endpoint endpoint)
|
|
WireTapDefinition(String uri)
|
Method Summary | |
---|---|
void |
addOutput(ProcessorDefinition<?> output)
Adds the given definition as output to this block |
WireTapDefinition<Type> |
copy()
Uses a copy of the original exchange |
WireTapDefinition<Type> |
copy(boolean copy)
Uses a copy of the original exchange |
Processor |
createProcessor(RouteContext routeContext)
Override this in definition class and implement logic to create the processor based on the definition model. |
protected String |
description()
|
Type |
end()
Ends the current block |
WireTapDefinition<Type> |
executorService(ExecutorService executorService)
Uses a custom thread pool |
WireTapDefinition<Type> |
executorServiceRef(String executorServiceRef)
Uses a custom thread pool |
Boolean |
getCopy()
|
Endpoint |
getEndpoint()
|
String |
getEndpointUri()
Gets the uri of the endpoint used by this definition. |
ExecutorService |
getExecutorService()
Gets the executor service |
String |
getExecutorServiceRef()
Gets the reference to lookup in the Registry for the executor service to be used. |
List<SetHeaderDefinition> |
getHeaders()
|
String |
getLabel()
Returns a label to describe this node such as the expression if some kind of expression node |
ExpressionSubElementDefinition |
getNewExchangeExpression()
|
Processor |
getNewExchangeProcessor()
|
String |
getNewExchangeProcessorRef()
|
Processor |
getOnPrepare()
|
String |
getOnPrepareRef()
|
ExchangePattern |
getPattern()
|
String |
getRef()
|
String |
getShortName()
Returns a short name for this node which can be useful for ID generation or referring to related resources like images |
String |
getUri()
|
boolean |
isCopy()
|
WireTapDefinition<Type> |
newExchange(Expression expression)
Deprecated. will be removed in Camel 3.0 Instead use newExchangeBody(org.apache.camel.Expression) |
WireTapDefinition<Type> |
newExchange(Processor processor)
Sends a new Exchange, instead of tapping an existing, using ExchangePattern.InOnly |
WireTapDefinition<Type> |
newExchangeBody(Expression expression)
Sends a new Exchange, instead of tapping an existing, using ExchangePattern.InOnly |
WireTapDefinition<Type> |
newExchangeHeader(String headerName,
Expression expression)
Sets a header on the new Exchange, instead of tapping an existing, using ExchangePattern.InOnly . |
WireTapDefinition<Type> |
newExchangeRef(String ref)
Sends a new Exchange, instead of tapping an existing, using ExchangePattern.InOnly |
WireTapDefinition<Type> |
onPrepare(Processor onPrepare)
Uses the Processor when preparing the Exchange to be send. |
WireTapDefinition<Type> |
onPrepareRef(String onPrepareRef)
Uses the Processor when preparing the Exchange to be send. |
Endpoint |
resolveEndpoint(RouteContext context)
|
void |
setCopy(Boolean copy)
|
void |
setEndpoint(Endpoint endpoint)
|
void |
setExecutorService(ExecutorService executorService)
Sets the executor service to be used. |
void |
setExecutorServiceRef(String executorServiceRef)
Sets a reference to lookup in the Registry for the executor service to be used. |
void |
setHeaders(List<SetHeaderDefinition> headers)
|
void |
setNewExchangeExpression(Expression expression)
|
void |
setNewExchangeExpression(ExpressionSubElementDefinition expression)
|
void |
setNewExchangeProcessor(Processor processor)
|
void |
setNewExchangeProcessorRef(String ref)
|
void |
setOnPrepare(Processor onPrepare)
|
void |
setOnPrepareRef(String onPrepareRef)
|
void |
setRef(String ref)
|
void |
setUri(String uri)
|
String |
toString()
|
Methods inherited from class org.apache.camel.model.NoOutputDefinition |
---|
getOutputs, isOutputSupported |
Methods inherited from class org.apache.camel.model.OptionalIdentifiedDefinition |
---|
description, getDescription, getDescriptionText, getId, hasCustomIdAssigned, idOrCreate, isCustomId, setCustomId, setDescription, setId |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected String uri
protected String ref
protected Endpoint endpoint
Constructor Detail |
---|
public WireTapDefinition()
public WireTapDefinition(String uri)
public WireTapDefinition(Endpoint endpoint)
Method Detail |
---|
public String getEndpointUri()
EndpointRequiredDefinition
getEndpointUri
in interface EndpointRequiredDefinition
public Processor createProcessor(RouteContext routeContext) throws Exception
ProcessorDefinition
createProcessor
in class ProcessorDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
Exception
public ExchangePattern getPattern()
public String toString()
toString
in class Object
protected String description()
public String getShortName()
OptionalIdentifiedDefinition
getShortName
in interface NamedNode
getShortName
in class OptionalIdentifiedDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
public String getLabel()
ProcessorDefinition
getLabel
in interface NamedNode
getLabel
in class ProcessorDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
public Type end()
ProcessorDefinition
end
in class ProcessorDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
public void addOutput(ProcessorDefinition<?> output)
Block
addOutput
in interface Block
addOutput
in class ProcessorDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
output
- the processor definitionpublic Endpoint resolveEndpoint(RouteContext context)
public WireTapDefinition<Type> executorService(ExecutorService executorService)
executorService
in interface ExecutorServiceAwareDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
executorService
- a custom ExecutorService
to use as thread pool
for sending tapped exchanges
public WireTapDefinition<Type> executorServiceRef(String executorServiceRef)
executorServiceRef
in interface ExecutorServiceAwareDefinition<WireTapDefinition<Type extends ProcessorDefinition<Type>>>
executorServiceRef
- reference to lookup a custom ExecutorService
to use as thread pool for sending tapped exchanges
public WireTapDefinition<Type> copy()
public WireTapDefinition<Type> copy(boolean copy)
copy
- if it is true camel will copy the original exchange,
if it is false camel will not copy the original exchange
@Deprecated public WireTapDefinition<Type> newExchange(Expression expression)
newExchangeBody(org.apache.camel.Expression)
public WireTapDefinition<Type> newExchangeBody(Expression expression)
ExchangePattern.InOnly
expression
- expression that creates the new body to send
newExchangeHeader(String, org.apache.camel.Expression)
public WireTapDefinition<Type> newExchangeRef(String ref)
ExchangePattern.InOnly
ref
- reference to the Processor
to lookup in the Registry
to
be used for preparing the new exchange to send
public WireTapDefinition<Type> newExchange(Processor processor)
ExchangePattern.InOnly
processor
- processor preparing the new exchange to send
newExchangeHeader(String, org.apache.camel.Expression)
public WireTapDefinition<Type> newExchangeHeader(String headerName, Expression expression)
ExchangePattern.InOnly
.
Use this together with the newExchange(org.apache.camel.Expression)
or newExchange(org.apache.camel.Processor)
methods.
headerName
- the header nameexpression
- the expression setting the header value
public WireTapDefinition<Type> onPrepare(Processor onPrepare)
Processor
when preparing the Exchange
to be send.
This can be used to deep-clone messages that should be send, or any custom logic needed before
the exchange is send.
onPrepare
- the processor
public WireTapDefinition<Type> onPrepareRef(String onPrepareRef)
Processor
when preparing the Exchange
to be send.
This can be used to deep-clone messages that should be send, or any custom logic needed before
the exchange is send.
onPrepareRef
- reference to the processor to lookup in the Registry
public String getUri()
public void setUri(String uri)
public String getRef()
public void setRef(String ref)
public Endpoint getEndpoint()
public void setEndpoint(Endpoint endpoint)
public Processor getNewExchangeProcessor()
public void setNewExchangeProcessor(Processor processor)
public String getNewExchangeProcessorRef()
public void setNewExchangeProcessorRef(String ref)
public ExpressionSubElementDefinition getNewExchangeExpression()
public void setNewExchangeExpression(ExpressionSubElementDefinition expression)
public void setNewExchangeExpression(Expression expression)
public ExecutorService getExecutorService()
ExecutorServiceAware
getExecutorService
in interface ExecutorServiceAware
public void setExecutorService(ExecutorService executorService)
ExecutorServiceAware
setExecutorService
in interface ExecutorServiceAware
executorService
- the executorpublic String getExecutorServiceRef()
ExecutorServiceAware
Registry
for the executor service to be used.
getExecutorServiceRef
in interface ExecutorServiceAware
public void setExecutorServiceRef(String executorServiceRef)
ExecutorServiceAware
Registry
for the executor service to be used.
setExecutorServiceRef
in interface ExecutorServiceAware
executorServiceRef
- reference for the executorpublic Boolean getCopy()
public void setCopy(Boolean copy)
public boolean isCopy()
public String getOnPrepareRef()
public void setOnPrepareRef(String onPrepareRef)
public Processor getOnPrepare()
public void setOnPrepare(Processor onPrepare)
public List<SetHeaderDefinition> getHeaders()
public void setHeaders(List<SetHeaderDefinition> headers)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |