You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2019/12/09 19:05:16 UTC
[camel] branch master updated: Put the example of skipHeaderRecord
csv unmarshal
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/master by this push:
new ccb8ae1 Put the example of skipHeaderRecord csv unmarshal
new eaabad1 Merge pull request #3395 from laertida/patch-1
ccb8ae1 is described below
commit ccb8ae144978599c34913a43b0d68578e635db3c
Author: Laurencio <la...@gmail.com>
AuthorDate: Mon Dec 9 12:56:10 2019 -0600
Put the example of skipHeaderRecord csv unmarshal
Documentation did explains how to skip the first line on header for versions until 2.15, but did not when version is 2.16.5. Method is different.
I added an example and a message to avoid test with an outdated method.
---
components/camel-csv/src/main/docs/csv-dataformat.adoc | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/components/camel-csv/src/main/docs/csv-dataformat.adoc b/components/camel-csv/src/main/docs/csv-dataformat.adoc
index 80b3999..9098b9f 100644
--- a/components/camel-csv/src/main/docs/csv-dataformat.adoc
+++ b/components/camel-csv/src/main/docs/csv-dataformat.adoc
@@ -305,7 +305,22 @@ should illustrate this customization.
</bean>
-----------------------------------------------------------------------------------------------------------------------------
-== Using skipFirstLine option while unmarshaling
+== Using skipFirstLine or skipHeaderRecord option while unmarshaling
+
+*For Camel >= 2.16.5
+The instruction for CSV Data format to skip headers or first line is the following.
+Usign the Spring/XML DSL:
+
+[source,xml]
+---------------------------------------------------
+<route>
+ <from uri="direct:start" />
+ <unmarshal>
+ <csv skipHeaderRecord="true" />
+ </unmarshal>
+ <to uri="bean:myCsvHandler?method=doHandleCsv" />
+</route>
+---------------------------------------------------
*Since Camel 2.10 and deleted for Camel 2.15*