You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by renamsavio <re...@gmail.com> on 2013/01/17 20:16:29 UTC

End of Line - File component

Hi there,

I've been facing a problem about 'end of line' in text files.
I have a file component which reads some files in a directory, then I use
*.split(body(String.class).tokenize("\n"))* inside the route to split line
by line from each file. I want to be able to identify in which enviroment
each file was created(Windows,MacOS or Linux/Unix). For example, whether EOL
is Linux, "\n" simply doesn't work..Is there any way to do that..?

I hope I was clear about the problem.
Thanks!  



--
View this message in context: http://camel.465427.n5.nabble.com/End-of-Line-File-component-tp5725717.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: End of Line - File component

Posted by Christian Müller <ch...@gmail.com>.
Why? I can also create files with only "\n" line termination on Windows.

Sent from a mobile device
Am 17.01.2013 20:33 schrieb "renamsavio" <re...@gmail.com>:

> Hi there,
>
> I've been facing a problem about 'end of line' in text files.
> I have a file component which reads some files in a directory, then I use
> *.split(body(String.class).tokenize("\n"))* inside the route to split line
> by line from each file. I want to be able to identify in which enviroment
> each file was created(Windows,MacOS or Linux/Unix). For example, whether
> EOL
> is Linux, "\n" simply doesn't work..Is there any way to do that..?
>
> I hope I was clear about the problem.
> Thanks!
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/End-of-Line-File-component-tp5725717.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>