You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by cmoulliard <cm...@gmail.com> on 2008/08/07 12:29:38 UTC
@OutHeader does not exist ???
Hi,
In the Bean component, it is mentioned that a @OutHeader annotation exists
Using Annotations to bind parameters to the Exchange
The annotations can be used to bind in situations where traditional methods
would result in ambiguous methods. So by adding annotations you can decorate
your bean to help Camel invoke the correct method.
You can also use the following annotations to bind parameters to different
kinds of Expression
Annotation Meaning
@Body To bind to an inbound message body
@Header To bind to an inbound message header
@Headers To bind to the Map of the inbound message headers
@OutHeader To bind to an outbound message header
@OutHeaders To bind to the Map of the outbound message headers
@Property To bind to a named property on the exchange
@Properties To bind to the property map on the exchange
but the jar of Camel-1.4 does not contain such a class ?
Is it an error in the doc or a ghost class ?
Kind regards,
Charles Moulliard
-----
Enterprise Architect
Xpectis
12, route d'Esch
L-1470 Luxembourg
Phone +352 25 10 70 470
Mobile +352 621 45 36 22
e-mail : cmoulliard@xpectis.com
web site : www.xpectis.com
--
View this message in context: http://www.nabble.com/%40OutHeader-does-not-exist-----tp18867683s22882p18867683.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: @OutHeader does not exist ???
Posted by Roman Kalukiewicz <ro...@gmail.com>.
Hello,
I believe @OutHeader is something that cannot exist actually.
When your bean endpoint receives a message it has no out message at
all, because it is your bean that will create out message.
@OutHeaders is better, because it is a map, so you can add headers to
out message, but @OutHeader should always return null, as on method
invocation there is no header at all.
Or maybe there was another idea about handling @OutHeader?
Roman
2008/8/7 cmoulliard <cm...@gmail.com>:
>
> Hi,
>
> In the Bean component, it is mentioned that a @OutHeader annotation exists
>
> Using Annotations to bind parameters to the Exchange
>
> The annotations can be used to bind in situations where traditional methods
> would result in ambiguous methods. So by adding annotations you can decorate
> your bean to help Camel invoke the correct method.
>
> You can also use the following annotations to bind parameters to different
> kinds of Expression
> Annotation Meaning
> @Body To bind to an inbound message body
> @Header To bind to an inbound message header
> @Headers To bind to the Map of the inbound message headers
> @OutHeader To bind to an outbound message header
> @OutHeaders To bind to the Map of the outbound message headers
> @Property To bind to a named property on the exchange
> @Properties To bind to the property map on the exchange
>
> but the jar of Camel-1.4 does not contain such a class ?
>
> Is it an error in the doc or a ghost class ?
>
> Kind regards,
>
> Charles Moulliard
>
> -----
> Enterprise Architect
>
> Xpectis
> 12, route d'Esch
> L-1470 Luxembourg
>
> Phone +352 25 10 70 470
> Mobile +352 621 45 36 22
>
> e-mail : cmoulliard@xpectis.com
> web site : www.xpectis.com
> --
> View this message in context: http://www.nabble.com/%40OutHeader-does-not-exist-----tp18867683s22882p18867683.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
>