You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by deloughry <si...@dedicationgroup.com> on 2011/08/23 05:05:37 UTC
Trying to set fixed length bindy type data formatter in
RouteBuilder.
Is there a way to indicate a fixed length bindy type in
RouteBuilder.configure? Similar to -
public void configure() throws Exception {
from("file://target/inbox2")
.unmarshal()
.bindy(BindyType.Csv,
"com.example.fixedlengthrecord.bindy")
.process(new ListMapToValueObjectProcessor()).split(body())
.process(new ExampleTransformer())
.to("file://target/outbox2");
}
There is no BindyType enum for fixed length types.
--
View this message in context: http://camel.465427.n5.nabble.com/Trying-to-set-fixed-length-bindy-type-data-formatter-in-RouteBuilder-tp4725299p4725299.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Trying to set fixed length bindy type data formatter in RouteBuilder.
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
On Tue, Aug 23, 2011 at 5:05 AM, deloughry
<si...@dedicationgroup.com> wrote:
> Is there a way to indicate a fixed length bindy type in
> RouteBuilder.configure? Similar to -
>
> public void configure() throws Exception {
>
> from("file://target/inbox2")
> .unmarshal()
> .bindy(BindyType.Csv,
> "com.example.fixedlengthrecord.bindy")
> .process(new ListMapToValueObjectProcessor()).split(body())
> .process(new ExampleTransformer())
> .to("file://target/outbox2");
> }
>
> There is no BindyType enum for fixed length types.
>
Thanks for reporting. I have added that missing type.
https://issues.apache.org/jira/browse/CAMEL-4369
Instead you would have to create the fixed length by yourself
DataFormat df = new FixedLengthBindyDataFormat("com.foo");
And then refer to it in the unmarshal in the route:
.unmarshal(df)
> --
> View this message in context: http://camel.465427.n5.nabble.com/Trying-to-set-fixed-length-bindy-type-data-formatter-in-RouteBuilder-tp4725299p4725299.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
--
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/