|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ProducerTemplate<E extends Exchange>
Template (named like Spring's TransactionTemplate & JmsTemplate
et al) for working with Camel and sending Message
instances in an
Exchange
to an Endpoint
.
RuntimeCamelException
if processing of
the Exchange
failed and an Exception occured. The getCause
method on RuntimeCamelException
returns the wrapper original caused
exception.
All the sendBody methods will return the content according to this strategy
RuntimeCamelException
as stated above
Method Summary | |
---|---|
E |
request(Endpoint<E> endpoint,
Processor processor)
Sends an exchange to an endpoint using a supplied processor Uses an ExchangePattern.InOut message exchange pattern. |
Exchange |
request(String endpointUri,
Processor processor)
Sends an exchange to an endpoint using a supplied processor Uses an ExchangePattern.InOut message exchange pattern. |
Object |
requestBody(Endpoint<E> endpoint,
Object body)
Send the body to an endpoint returning any result output body. |
Object |
requestBody(String endpointUri,
Object body)
Send the body to an endpoint returning any result output body. |
Object |
requestBodyAndHeader(Endpoint<E> endpoint,
Object body,
String header,
Object headerValue)
Send the body to an endpoint returning any result output body. |
Object |
requestBodyAndHeader(String endpointUri,
Object body,
String header,
Object headerValue)
Send the body to an endpoint returning any result output body. |
Object |
requestBodyAndHeaders(Endpoint<E> endpoint,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values. |
Object |
requestBodyAndHeaders(String endpointUri,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values. |
E |
send(E exchange)
Sends the exchange to the default endpoint |
E |
send(Endpoint<E> endpoint,
E exchange)
Sends the exchange to the given endpoint |
E |
send(Endpoint<E> endpoint,
ExchangePattern pattern,
Processor processor)
Sends an exchange to an endpoint using a supplied processor |
E |
send(Endpoint<E> endpoint,
Processor processor)
Sends an exchange to an endpoint using a supplied processor |
E |
send(Endpoint<E> endpoint,
Processor processor,
AsyncCallback callback)
Sends an exchange to an endpoint using a supplied processor |
E |
send(Processor processor)
Sends an exchange to the default endpoint using a supplied processor |
E |
send(String endpointUri,
E exchange)
Sends the exchange to the given endpoint |
E |
send(String endpointUri,
ExchangePattern pattern,
Processor processor)
Sends an exchange to an endpoint using a supplied processor |
E |
send(String endpointUri,
Processor processor)
Sends an exchange to an endpoint using a supplied processor |
E |
send(String endpointUri,
Processor processor,
AsyncCallback callback)
Sends an exchange to an endpoint using a supplied processor |
Object |
sendBody(Endpoint<E> endpoint,
ExchangePattern pattern,
Object body)
Send the body to an endpoint with the given ExchangePattern
returning any result output body |
Object |
sendBody(Endpoint<E> endpoint,
Object body)
Send the body to an endpoint returning any result output body |
Object |
sendBody(Object body)
Sends the body to the default endpoint and returns the result content |
Object |
sendBody(String endpointUri,
ExchangePattern pattern,
Object body)
Send the body to an endpoint returning any result output body |
Object |
sendBody(String endpointUri,
Object body)
Send the body to an endpoint returning any result output body |
Object |
sendBodyAndHeader(Endpoint<E> endpoint,
ExchangePattern pattern,
Object body,
String header,
Object headerValue)
Sends the body to an endpoint with a specified header and header value |
Object |
sendBodyAndHeader(Endpoint<E> endpoint,
Object body,
String header,
Object headerValue)
Sends the body to an endpoint with a specified header and header value |
Object |
sendBodyAndHeader(Object body,
String header,
Object headerValue)
Sends the body to the default endpoint with a specified header and header value |
Object |
sendBodyAndHeader(String endpoint,
ExchangePattern pattern,
Object body,
String header,
Object headerValue)
Sends the body to an endpoint with a specified header and header value |
Object |
sendBodyAndHeader(String endpointUri,
Object body,
String header,
Object headerValue)
Sends the body to an endpoint with a specified header and header value |
Object |
sendBodyAndHeaders(Endpoint<E> endpoint,
ExchangePattern pattern,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values |
Object |
sendBodyAndHeaders(Endpoint<E> endpoint,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values |
Object |
sendBodyAndHeaders(Object body,
Map<String,Object> headers)
Sends the body to the default endpoint with the specified headers and header values |
Object |
sendBodyAndHeaders(String endpointUri,
ExchangePattern pattern,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values |
Object |
sendBodyAndHeaders(String endpointUri,
Object body,
Map<String,Object> headers)
Sends the body to an endpoint with the specified headers and header values |
Methods inherited from interface org.apache.camel.Service |
---|
start, stop |
Method Detail |
---|
E send(E exchange)
exchange
- the exchange to send
E send(Processor processor)
processor
- the transformer used to populate the new exchange
Processor
to populate the exchange
Object sendBody(Object body)
body
- the payload to send
Object sendBodyAndHeader(Object body, String header, Object headerValue)
body
- the payload to sendheader
- the header nameheaderValue
- the header value
Object sendBodyAndHeaders(Object body, Map<String,Object> headers)
body
- the payload to sendheaders
- the headers
E send(String endpointUri, E exchange)
endpointUri
- the endpoint URI to send the exchange toexchange
- the exchange to send
E send(String endpointUri, Processor processor)
endpointUri
- the endpoint URI to send the exchange toprocessor
- the transformer used to populate the new exchange
Processor
to populate the exchange
E send(String endpointUri, ExchangePattern pattern, Processor processor)
endpointUri
- the endpoint URI to send the exchange topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
processor
- the transformer used to populate the new exchange
Processor
to populate the exchange
E send(String endpointUri, Processor processor, AsyncCallback callback)
endpointUri
- the endpoint URI to send the exchange toprocessor
- the transformer used to populate the new exchange
Processor
to populate the exchange.callback
- the callback will be called when the exchange is completed.
E send(Endpoint<E> endpoint, E exchange)
endpoint
- the endpoint to send the exchange toexchange
- the exchange to send
E send(Endpoint<E> endpoint, Processor processor)
endpoint
- the endpoint to send the exchange toprocessor
- the transformer used to populate the new exchange
Processor
to populate the exchange
E send(Endpoint<E> endpoint, ExchangePattern pattern, Processor processor)
endpoint
- the endpoint to send the exchange topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
processor
- the transformer used to populate the new exchange
Processor
to populate the exchange
E send(Endpoint<E> endpoint, Processor processor, AsyncCallback callback)
endpoint
- the endpoint to send the exchange toprocessor
- the transformer used to populate the new exchange
Processor
to populate the exchange.callback
- the callback will be called when the exchange is completed.
Object sendBody(Endpoint<E> endpoint, Object body)
endpoint
- the endpoint to send the exchange tobody
- the payload
Object sendBody(String endpointUri, Object body)
endpointUri
- the endpoint URI to send the exchange tobody
- the payload
Object sendBody(Endpoint<E> endpoint, ExchangePattern pattern, Object body)
ExchangePattern
returning any result output body
endpoint
- the endpoint to send the exchange tobody
- the payloadpattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
Object sendBody(String endpointUri, ExchangePattern pattern, Object body)
endpointUri
- the endpoint URI to send the exchange topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
body
- the payload
Object sendBodyAndHeader(String endpointUri, Object body, String header, Object headerValue)
endpointUri
- the endpoint URI to send tobody
- the payload to sendheader
- the header nameheaderValue
- the header value
Object sendBodyAndHeader(Endpoint<E> endpoint, Object body, String header, Object headerValue)
endpoint
- the Endpoint to send tobody
- the payload to sendheader
- the header nameheaderValue
- the header value
Object sendBodyAndHeader(Endpoint<E> endpoint, ExchangePattern pattern, Object body, String header, Object headerValue)
endpoint
- the Endpoint to send topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
body
- the payload to sendheader
- the header nameheaderValue
- the header value
Object sendBodyAndHeader(String endpoint, ExchangePattern pattern, Object body, String header, Object headerValue)
endpoint
- the Endpoint URI to send topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
body
- the payload to sendheader
- the header nameheaderValue
- the header value
Object sendBodyAndHeaders(String endpointUri, Object body, Map<String,Object> headers)
endpointUri
- the endpoint URI to send tobody
- the payload to sendheaders
- headers
Object sendBodyAndHeaders(Endpoint<E> endpoint, Object body, Map<String,Object> headers)
endpoint
- the endpoint URI to send tobody
- the payload to sendheaders
- headers
Object sendBodyAndHeaders(String endpointUri, ExchangePattern pattern, Object body, Map<String,Object> headers)
endpointUri
- the endpoint URI to send topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
body
- the payload to sendheaders
- headers
Object sendBodyAndHeaders(Endpoint<E> endpoint, ExchangePattern pattern, Object body, Map<String,Object> headers)
endpoint
- the endpoint URI to send topattern
- the message ExchangePattern
such as
ExchangePattern.InOnly
or ExchangePattern.InOut
body
- the payload to sendheaders
- headers
E request(Endpoint<E> endpoint, Processor processor)
ExchangePattern.InOut
message exchange pattern.
endpoint
- the Endpoint to send toprocessor
- the processor which will populate the exchange before sending
Exchange request(String endpointUri, Processor processor)
ExchangePattern.InOut
message exchange pattern.
endpointUri
- the endpoint URI to send toprocessor
- the processor which will populate the exchange before sending
Object requestBody(Endpoint<E> endpoint, Object body)
ExchangePattern.InOut
message exchange pattern.
endpoint
- the Endpoint to send tobody
- the payload
Object requestBody(String endpointUri, Object body)
ExchangePattern.InOut
message exchange pattern.
endpointUri
- the endpoint URI to send tobody
- the payload
Object requestBodyAndHeader(Endpoint<E> endpoint, Object body, String header, Object headerValue)
ExchangePattern.InOut
message exchange pattern.
endpoint
- the Endpoint to send tobody
- the payloadheader
- the header nameheaderValue
- the header value
Object requestBodyAndHeader(String endpointUri, Object body, String header, Object headerValue)
ExchangePattern.InOut
message exchange pattern.
endpointUri
- the endpoint URI to send tobody
- the payloadheader
- the header nameheaderValue
- the header value
Object requestBodyAndHeaders(String endpointUri, Object body, Map<String,Object> headers)
ExchangePattern.InOut
message exchange pattern.
endpointUri
- the endpoint URI to send tobody
- the payload to sendheaders
- headers
Object requestBodyAndHeaders(Endpoint<E> endpoint, Object body, Map<String,Object> headers)
ExchangePattern.InOut
message exchange pattern.
endpoint
- the endpoint URI to send tobody
- the payload to sendheaders
- headers
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |