java 骆驼读取文件内容

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/14937291/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-31 17:55:58  来源:igfitidea点击:

Camel Read File Content

javafileapache-camel

提问by Neron

Is there a way(api function) to read the whole content of a file(or line by line) in camel without writing a converter or any java code?

有没有一种方法(api 函数)可以在不编写转换器或任何 Java 代码的情况下读取骆驼文件的全部内容(或逐行)?

Thanks

谢谢

回答by Neron

Found it, Sorry guys for bothering:

找到了,麻烦各位了:

from("file://inputdir/").convertBodyTo(String.class)