You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by bu...@apache.org on 2017/08/25 09:20:43 UTC

svn commit: r1017266 [1/17] - in /websites/production/camel/content: ./ cache/

Author: buildbot
Date: Fri Aug 25 09:20:43 2017
New Revision: 1017266

Log:
Production update by buildbot for camel

Modified:
    websites/production/camel/content/bean-binding.html
    websites/production/camel/content/beanio.html
    websites/production/camel/content/book-in-one-page.html
    websites/production/camel/content/cache/main.pageCache
    websites/production/camel/content/crypto-digital-signatures.html
    websites/production/camel/content/crypto.html
    websites/production/camel/content/ftp.html
    websites/production/camel/content/ftp2.html
    websites/production/camel/content/hawtdb.html
    websites/production/camel/content/jasypt.html
    websites/production/camel/content/jaxb.html
    websites/production/camel/content/leveldb.html
    websites/production/camel/content/message-filter.html
    websites/production/camel/content/message-translator.html
    websites/production/camel/content/multicast.html
    websites/production/camel/content/pipes-and-filters.html
    websites/production/camel/content/properties.html
    websites/production/camel/content/resequencer.html
    websites/production/camel/content/restlet.html
    websites/production/camel/content/rss.html
    websites/production/camel/content/servlet.html
    websites/production/camel/content/simple.html
    websites/production/camel/content/splitter.html
    websites/production/camel/content/spring-java-config.html
    websites/production/camel/content/spring-remoting.html
    websites/production/camel/content/using-propertyplaceholder.html
    websites/production/camel/content/velocity.html
    websites/production/camel/content/xmlrpc.html
    websites/production/camel/content/xquery.html

Modified: websites/production/camel/content/bean-binding.html
==============================================================================
--- websites/production/camel/content/bean-binding.html (original)
+++ websites/production/camel/content/bean-binding.html Fri Aug 25 09:20:43 2017
@@ -36,17 +36,6 @@
     <![endif]-->
 
 
-  <link href='//camel.apache.org/styles/highlighter/styles/shCoreCamel.css' rel='stylesheet' type='text/css' />
-  <link href='//camel.apache.org/styles/highlighter/styles/shThemeCamel.css' rel='stylesheet' type='text/css' />
-  <script src='//camel.apache.org/styles/highlighter/scripts/shCore.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
-  
-  <script type="text/javascript">
-  SyntaxHighlighter.defaults['toolbar'] = false;
-  SyntaxHighlighter.all();
-  </script>
 
     <title>
     Apache Camel: Bean Binding
@@ -86,148 +75,47 @@
 	<tbody>
         <tr>
         <td valign="top" width="100%">
-<div class="wiki-content maincontent"><h2 id="BeanBinding-BeanBinding">Bean Binding</h2><p>Bean Binding in Camel defines both which methods are invoked and also how the <a shape="rect" href="message.html">Message</a> is converted into the parameters of the method when it is invoked.</p><h3 id="BeanBinding-Choosingthemethodtoinvoke">Choosing the method to invoke</h3><p>The binding of a Camel <a shape="rect" href="message.html">Message</a> to a bean method call can occur in different ways, in the following order of importance:</p><ul><li>if the message contains the header <strong>CamelBeanMethodName</strong> then that method is invoked, converting the body to the type of the method's argument.<ul><li>From <strong>Camel 2.8</strong> onwards you can qualify parameter types to select exactly which method to use among overloads with the same name (see below for more details).</li><li>From <strong>Camel 2.9</strong> onwards you can specify parameter values directly in the method option (se
 e below for more details).</li></ul></li><li>you can explicitly specify the method name in the <a shape="rect" href="dsl.html">DSL</a> or when using <a shape="rect" href="pojo-consuming.html">POJO Consuming</a> or <a shape="rect" href="pojo-producing.html">POJO Producing</a></li><li>if the bean has a method marked with the <code>@Handler</code> annotation, then that method is selected</li><li>if the bean can be converted to a <a shape="rect" href="processor.html">Processor</a> using the <a shape="rect" href="type-converter.html">Type Converter</a> mechanism, then this is used to process the message. The <a shape="rect" href="activemq.html">ActiveMQ</a> component uses this mechanism to allow any JMS MessageListener to be invoked directly by Camel without having to write any integration glue code. You can use the same mechanism to integrate Camel into any other messaging/remoting frameworks.</li><li>if the body of the message can be converted to a <a shape="rect" class="external-link"
  href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/component/bean/BeanInvocation.html">BeanInvocation</a> (the default payload used by the <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/component/bean/ProxyHelper.html">ProxyHelper</a>) component - then that is used to invoke the method and pass its arguments</li><li>otherwise the type of the body is used to find a matching method; an error is thrown if a single method cannot be chosen unambiguously.</li><li>you can also use Exchange as the parameter itself, but then the return type must be void.</li><li>if the bean class is private (or package-private), interface methods will be preferred (from <strong>Camel 2.9</strong> onwards) since Camel can't invoke class methods on such beans</li></ul><p>In cases where Camel cannot choose a method to invoke, an <code>AmbiguousMethodCallException</code> is thrown.</p><p>By default the return val
 ue is set on the outbound message body.&#160;</p><h3 id="BeanBinding-Asynchronousprocessing">Asynchronous processing</h3><p>From&#160;<strong>Camel 2.18</strong>&#160;onwards you can return a CompletionStage implementation (e.g. a CompletableFuture) to implement asynchronous processing.</p><p>Please be sure to properly complete the CompletionStage with the result or exception, including any timeout handling. Exchange processing would wait for completion and would not impose any timeouts automatically. It's extremely useful to monitor&#160;<a shape="rect" class="external-link" href="https://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/InflightRepository.html">Inflight repository</a> for any hanging messages.</p><p>Note that completing with "null" won't set outbody message body to null, but would keep message intact. This is useful to support methods that don't modify exchange and return CompletableFuture&lt;Void&gt;. To set body to null, just add Exchange me
 thod parameter and directly modify exchange messages.</p><p>Examples:</p><p>Simple asynchronous processor, modifying message body.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public CompletableFuture&lt;String&gt; doSomethingAsync(String body)]]></script>
-</div></div><p>Composite processor that do not modify exchange</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public CompletableFuture&lt;Void&gt; doSomethingAsync(String body) {
+<div class="wiki-content maincontent"><h2 id="BeanBinding-BeanBinding">Bean Binding</h2><p>Bean Binding in Camel defines both which methods are invoked and also how the <a shape="rect" href="message.html">Message</a> is converted into the parameters of the method when it is invoked.</p><h3 id="BeanBinding-Choosingthemethodtoinvoke">Choosing the method to invoke</h3><p>The binding of a Camel <a shape="rect" href="message.html">Message</a> to a bean method call can occur in different ways, in the following order of importance:</p><ul><li>if the message contains the header <strong>CamelBeanMethodName</strong> then that method is invoked, converting the body to the type of the method's argument.<ul><li>From <strong>Camel 2.8</strong> onwards you can qualify parameter types to select exactly which method to use among overloads with the same name (see below for more details).</li><li>From <strong>Camel 2.9</strong> onwards you can specify parameter values directly in the method option (se
 e below for more details).</li></ul></li><li>you can explicitly specify the method name in the <a shape="rect" href="dsl.html">DSL</a> or when using <a shape="rect" href="pojo-consuming.html">POJO Consuming</a> or <a shape="rect" href="pojo-producing.html">POJO Producing</a></li><li>if the bean has a method marked with the <code>@Handler</code> annotation, then that method is selected</li><li>if the bean can be converted to a <a shape="rect" href="processor.html">Processor</a> using the <a shape="rect" href="type-converter.html">Type Converter</a> mechanism, then this is used to process the message. The <a shape="rect" href="activemq.html">ActiveMQ</a> component uses this mechanism to allow any JMS MessageListener to be invoked directly by Camel without having to write any integration glue code. You can use the same mechanism to integrate Camel into any other messaging/remoting frameworks.</li><li>if the body of the message can be converted to a <a shape="rect" class="external-link"
  href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/component/bean/BeanInvocation.html">BeanInvocation</a> (the default payload used by the <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/component/bean/ProxyHelper.html">ProxyHelper</a>) component - then that is used to invoke the method and pass its arguments</li><li>otherwise the type of the body is used to find a matching method; an error is thrown if a single method cannot be chosen unambiguously.</li><li>you can also use Exchange as the parameter itself, but then the return type must be void.</li><li>if the bean class is private (or package-private), interface methods will be preferred (from <strong>Camel 2.9</strong> onwards) since Camel can't invoke class methods on such beans</li></ul><p>In cases where Camel cannot choose a method to invoke, an <code>AmbiguousMethodCallException</code> is thrown.</p><p>By default the return val
 ue is set on the outbound message body.&#160;</p><h3 id="BeanBinding-Asynchronousprocessing">Asynchronous processing</h3><p>From&#160;<strong>Camel 2.18</strong>&#160;onwards you can return a CompletionStage implementation (e.g. a CompletableFuture) to implement asynchronous processing.</p><p>Please be sure to properly complete the CompletionStage with the result or exception, including any timeout handling. Exchange processing would wait for completion and would not impose any timeouts automatically. It's extremely useful to monitor&#160;<a shape="rect" class="external-link" href="https://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/InflightRepository.html">Inflight repository</a> for any hanging messages.</p><p>Note that completing with "null" won't set outbody message body to null, but would keep message intact. This is useful to support methods that don't modify exchange and return CompletableFuture&lt;Void&gt;. To set body to null, just add Exchange me
 thod parameter and directly modify exchange messages.</p><p>Examples:</p><p>Simple asynchronous processor, modifying message body.</p><parameter ac:name="language">java</parameter><plain-text-body>public CompletableFuture&lt;String&gt; doSomethingAsync(String body)</plain-text-body><p>Composite processor that do not modify exchange</p><parameter ac:name="language">java</parameter><plain-text-body>public CompletableFuture&lt;Void&gt; doSomethingAsync(String body) {
 	return CompletableFuture.allOf(doA(body), doB(body), doC());
-}]]></script>
-</div></div><h3 id="BeanBinding-Parameterbinding">Parameter binding</h3><p>When a method has been chosen for invocation, Camel will bind to the parameters of the method.</p><p>The following Camel-specific types are automatically bound:</p><ul class="alternate"><li><code>org.apache.camel.Exchange</code></li><li><code>org.apache.camel.Message</code></li><li><code>org.apache.camel.CamelContext</code></li><li><code>org.apache.camel.TypeConverter</code></li><li><code>org.apache.camel.spi.Registry</code></li><li><code>java.lang.Exception</code></li></ul><p>So, if you declare any of these types, they will be provided by Camel. <strong>Note that <code>Exception</code> will bind to the caught exception of the <a shape="rect" href="exchange.html">Exchange</a></strong> - so it's often usable if you employ a <a shape="rect" href="pojo.html">Pojo</a> to handle, e.g., an <code>onException</code> route.</p><p>What is most interesting is that Camel will also try to bind the body of the <a shape="re
 ct" href="exchange.html">Exchange</a> to the first parameter of the method signature (albeit not of any of the types above). So if, for instance, we declare a parameter as <code>String body</code>, then Camel will bind the IN body to this type. Camel will also automatically convert to the type declared in the method signature.</p><p>Let's review some examples:</p><p>Below is a simple method with a body binding. Camel will bind the IN body to the <code>body</code> parameter and convert it to a <code>String</code>.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public String doSomething(String body)
-]]></script>
-</div></div><p>In the following sample we got one of the automatically-bound types as well - for instance, a <code>Registry</code> that we can use to lookup beans.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public String doSomething(String body, Registry registry)
-]]></script>
-</div></div><p>We can use <a shape="rect" href="exchange.html">Exchange</a> as well:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public String doSomething(String body, Exchange exchange)
-]]></script>
-</div></div><p>You can also have multiple types:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public String doSomething(String body, Exchange exchange, TypeConverter converter)
-]]></script>
-</div></div><p>And imagine you use a <a shape="rect" href="pojo.html">Pojo</a> to handle a given custom exception <code>InvalidOrderException</code> - we can then bind that as well:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public String badOrder(String body, InvalidOrderException invalid)
-]]></script>
-</div></div><p>Notice that we can bind to it even if we use a sub type of <code>java.lang.Exception</code> as Camel still knows it's an exception and can bind the cause (if any exists).</p><p>So what about headers and other stuff? Well now it gets a bit tricky - so we can use annotations to help us, or specify the binding in the method name option.<br clear="none"> See the following sections for more detail.</p><h3 id="BeanBinding-BindingAnnotations">Binding Annotations</h3><p>You can use the <a shape="rect" href="parameter-binding-annotations.html">Parameter Binding Annotations</a> to customize how parameter values are created from the <a shape="rect" href="message.html">Message</a></p><h4 id="BeanBinding-Examples">Examples</h4><p>For example, a <a shape="rect" href="bean.html">Bean</a> such as:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public class Bar {
+}</plain-text-body><h3 id="BeanBinding-Parameterbinding">Parameter binding</h3><p>When a method has been chosen for invocation, Camel will bind to the parameters of the method.</p><p>The following Camel-specific types are automatically bound:</p><ul class="alternate"><li><code>org.apache.camel.Exchange</code></li><li><code>org.apache.camel.Message</code></li><li><code>org.apache.camel.CamelContext</code></li><li><code>org.apache.camel.TypeConverter</code></li><li><code>org.apache.camel.spi.Registry</code></li><li><code>java.lang.Exception</code></li></ul><p>So, if you declare any of these types, they will be provided by Camel. <strong>Note that <code>Exception</code> will bind to the caught exception of the <a shape="rect" href="exchange.html">Exchange</a></strong> - so it's often usable if you employ a <a shape="rect" href="pojo.html">Pojo</a> to handle, e.g., an <code>onException</code> route.</p><p>What is most interesting is that Camel will also try to bind the body of the <a sh
 ape="rect" href="exchange.html">Exchange</a> to the first parameter of the method signature (albeit not of any of the types above). So if, for instance, we declare a parameter as <code>String body</code>, then Camel will bind the IN body to this type. Camel will also automatically convert to the type declared in the method signature.</p><p>Let's review some examples:</p><p>Below is a simple method with a body binding. Camel will bind the IN body to the <code>body</code> parameter and convert it to a <code>String</code>.</p><plain-text-body>public String doSomething(String body)
+</plain-text-body><p>In the following sample we got one of the automatically-bound types as well - for instance, a <code>Registry</code> that we can use to lookup beans.</p><plain-text-body>public String doSomething(String body, Registry registry)
+</plain-text-body><p>We can use <a shape="rect" href="exchange.html">Exchange</a> as well:</p><plain-text-body>public String doSomething(String body, Exchange exchange)
+</plain-text-body><p>You can also have multiple types:</p><plain-text-body>public String doSomething(String body, Exchange exchange, TypeConverter converter)
+</plain-text-body><p>And imagine you use a <a shape="rect" href="pojo.html">Pojo</a> to handle a given custom exception <code>InvalidOrderException</code> - we can then bind that as well:</p><plain-text-body>public String badOrder(String body, InvalidOrderException invalid)
+</plain-text-body><p>Notice that we can bind to it even if we use a sub type of <code>java.lang.Exception</code> as Camel still knows it's an exception and can bind the cause (if any exists).</p><p>So what about headers and other stuff? Well now it gets a bit tricky - so we can use annotations to help us, or specify the binding in the method name option.<br clear="none"> See the following sections for more detail.</p><h3 id="BeanBinding-BindingAnnotations">Binding Annotations</h3><p>You can use the <a shape="rect" href="parameter-binding-annotations.html">Parameter Binding Annotations</a> to customize how parameter values are created from the <a shape="rect" href="message.html">Message</a></p><h4 id="BeanBinding-Examples">Examples</h4><p>For example, a <a shape="rect" href="bean.html">Bean</a> such as:</p><plain-text-body>public class Bar {
 
     public String doSomething(String body) {
       // process the in body and return whatever you want
-      return &quot;Bye World&quot;;
+      return "Bye World";
    }
-]]></script>
-</div></div><p>Or the Exchange example. Notice that the return type must be <strong>void</strong> when there is only a single parameter of the type <code>org.apache.camel.Exchange</code>:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public class Bar {
+</plain-text-body><p>Or the Exchange example. Notice that the return type must be <strong>void</strong> when there is only a single parameter of the type <code>org.apache.camel.Exchange</code>:</p><plain-text-body>public class Bar {
 
     public void doSomething(Exchange exchange) {
       // process the exchange
-      exchange.getIn().setBody(&quot;Bye World&quot;);
+      exchange.getIn().setBody("Bye World");
    }
-]]></script>
-</div></div><h4 id="BeanBinding-@Handler">@Handler</h4><p>You can mark a method in your bean with the @Handler annotation to indicate that this method should be used for <a shape="rect" href="bean-binding.html">Bean Binding</a>.<br clear="none"> This has an advantage as you need not specify a method name in the Camel route, and therefore do not run into problems after renaming the method in an IDE that can't find all its references.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public class Bar {
+</plain-text-body><h4 id="BeanBinding-@Handler">@Handler</h4><p>You can mark a method in your bean with the @Handler annotation to indicate that this method should be used for <a shape="rect" href="bean-binding.html">Bean Binding</a>.<br clear="none"> This has an advantage as you need not specify a method name in the Camel route, and therefore do not run into problems after renaming the method in an IDE that can't find all its references.</p><parameter ac:name="">java</parameter><plain-text-body>public class Bar {
 
     @Handler
     public String doSomething(String body) {
       // process the in body and return whatever you want
-      return &quot;Bye World&quot;;
+      return "Bye World";
    }
-]]></script>
-</div></div><h3 id="BeanBinding-Parameterbindingusingmethodoption">Parameter binding using method option</h3><p><strong>Available as of Camel 2.9</strong></p><p>Camel uses the following rules to determine if it's a parameter value in the method option</p><ul class="alternate"><li>The value is either <code>true</code> or <code>false</code> which denotes a boolean value</li><li>The value is a numeric value such as <code>123</code> or <code>7</code></li><li>The value is a String enclosed with either single or double quotes</li><li>The value is null which denotes a <code>null</code> value</li><li>It can be evaluated using the <a shape="rect" href="simple.html">Simple</a> language, which means you can use, e.g., body, header.foo and other <a shape="rect" href="simple.html">Simple</a> tokens. Notice the tokens must be enclosed with ${ }.</li></ul><p>Any other value is consider to be a type declaration instead - see the next section about specifying types for overloaded methods.</p><p>When
  invoking a <a shape="rect" href="bean.html">Bean</a> you can instruct Camel to invoke a specific method by providing the method name:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething&quot;)
-]]></script>
-</div></div><p>Here we tell Camel to invoke the doSomething method - Camel handles the parameters' binding. Now suppose the method has 2 parameters, and the 2nd parameter is a boolean where we want to pass in a true value:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public void doSomething(String payload, boolean highPriority) {
+</plain-text-body><h3 id="BeanBinding-Parameterbindingusingmethodoption">Parameter binding using method option</h3><p><strong>Available as of Camel 2.9</strong></p><p>Camel uses the following rules to determine if it's a parameter value in the method option</p><ul class="alternate"><li>The value is either <code>true</code> or <code>false</code> which denotes a boolean value</li><li>The value is a numeric value such as <code>123</code> or <code>7</code></li><li>The value is a String enclosed with either single or double quotes</li><li>The value is null which denotes a <code>null</code> value</li><li>It can be evaluated using the <a shape="rect" href="simple.html">Simple</a> language, which means you can use, e.g., body, header.foo and other <a shape="rect" href="simple.html">Simple</a> tokens. Notice the tokens must be enclosed with ${ }.</li></ul><p>Any other value is consider to be a type declaration instead - see the next section about specifying types for overloaded methods.</p><
 p>When invoking a <a shape="rect" href="bean.html">Bean</a> you can instruct Camel to invoke a specific method by providing the method name:</p><plain-text-body>   .bean(OrderService.class, "doSomething")
+</plain-text-body><p>Here we tell Camel to invoke the doSomething method - Camel handles the parameters' binding. Now suppose the method has 2 parameters, and the 2nd parameter is a boolean where we want to pass in a true value:</p><plain-text-body>public void doSomething(String payload, boolean highPriority) {
    ...
 }
-]]></script>
-</div></div><p>This is now possible in <strong>Camel 2.9</strong> onwards:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething(*, true)&quot;)
-]]></script>
-</div></div><p>In the example above, we defined the first parameter using the wild card symbol *, which tells Camel to bind this parameter to any type, and let Camel figure this out. The 2nd parameter has a fixed value of <code>true</code>. Instead of the wildcard symbol we can instruct Camel to use the message body as shown:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething(${body}, true)&quot;)
-]]></script>
-</div></div><p>The syntax of the parameters is using the <a shape="rect" href="simple.html">Simple</a> expression language so we have to use ${ } placeholders in the body to refer to the message body.</p><p>If you want to pass in a <code>null</code> value, then you can explicit define this in the method option as shown below:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .to(&quot;bean:orderService?method=doSomething(null, true)&quot;)
-]]></script>
-</div></div><p>Specifying <code>null</code> as a parameter value instructs Camel to force passing a <code>null</code> value.</p><p>Besides the message body, you can pass in the message headers as a <code>java.util.Map</code>:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomethingWithHeaders(${body}, ${headers})&quot;)
-]]></script>
-</div></div><p>You can also pass in other fixed values besides booleans. For example, you can pass in a String and an integer:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(MyBean.class, &quot;echo(&#39;World&#39;, 5)&quot;)
-]]></script>
-</div></div><p>In the example above, we invoke the echo method with two parameters. The first has the content 'World' (without quotes), and the 2nd has the value of 5.<br clear="none"> Camel will automatically convert these values to the parameters' types.</p><p>Having the power of the <a shape="rect" href="simple.html">Simple</a> language allows us to bind to message headers and other values such as:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething(${body}, ${header.high})&quot;)
-]]></script>
-</div></div><p>You can also use the OGNL support of the <a shape="rect" href="simple.html">Simple</a> expression language. Now suppose the message body is an object which has a method named <code>asXml</code>. To invoke the <code>asXml</code> method we can do as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething(${body.asXml}, ${header.high})&quot;)
-]]></script>
-</div></div><p>Instead of using <code>.bean</code> as shown in the examples above, you may want to use <code>.to</code> instead as shown:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .to(&quot;bean:orderService?method=doSomething(${body.asXml}, ${header.high})&quot;)
-]]></script>
-</div></div><h3 id="BeanBinding-Usingtypequalifierstoselectamongoverloadedmethods">Using type qualifiers to select among overloaded methods</h3><p><strong>Available as of Camel 2.8</strong></p><p>If you have a <a shape="rect" href="bean.html">Bean</a> with overloaded methods, you can now specify parameter types in the method name so Camel can match the method you intend to use.<br clear="none"> Given the following bean:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>MyBean</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-public static final class MyBean {
-
-    public String hello(String name) {
-        return &quot;Hello &quot; + name;
-    }
-
-    public String hello(String name, @Header(&quot;country&quot;) String country) {
-        return &quot;Hello &quot; + name + &quot; you are from &quot; + country;
-    }
-
-    public String times(String name, @Header(&quot;times&quot;) int times) {
-        StringBuilder sb = new StringBuilder();
-        for (int i = 0; i &lt; times; i++) {
-            sb.append(name);
-        }
-        return sb.toString();
-    }
-
-    public String times(byte[] data, @Header(&quot;times&quot;) int times) {
-        String s = new String(data);
-        StringBuilder sb = new StringBuilder();
-        for (int i = 0; i &lt; times; i++) {
-            sb.append(s);
-            if (i &lt; times - 1) {
-                sb.append(&quot;,&quot;);
-            }
-        }
-        return sb.toString();
-    }
-
-    public String times(String name, int times, char separator) {
-        StringBuilder sb = new StringBuilder();
-        for (int i = 0; i &lt; times; i++) {
-            sb.append(name);
-            if (i &lt; times - 1) {
-                sb.append(separator);
-            }
-        }
-        return sb.toString();
-    }
-
-}
-]]></script>
-</div></div>Then the <code>MyBean</code> has 2 overloaded methods with the names <code>hello</code> and <code>times</code>. So if we want to use the method which has 2 parameters we can do as follows in the Camel route:<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Invoke 2 parameter method</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-from(&quot;direct:start&quot;)
-    .bean(MyBean.class, &quot;hello(String,String)&quot;)
-    .to(&quot;mock:result&quot;);
-]]></script>
-</div></div>We can also use a <code>*</code> as wildcard so we can just say we want to execute the method with 2 parameters we do<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Invoke 2 parameter method using wildcard</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-from(&quot;direct:start&quot;)
-    .bean(MyBean.class, &quot;hello(*,*)&quot;)
-    .to(&quot;mock:result&quot;);
-]]></script>
-</div></div>By default Camel will match the type name using the simple name, e.g. any leading package name will be disregarded. However if you want to match using the FQN, then specify the FQN type and Camel will leverage that. So if you have a <code>com.foo.MyOrder</code> and you want to match against the FQN, and <strong>not</strong> the simple name "MyOrder", then follow this example:<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[   .bean(OrderService.class, &quot;doSomething(com.foo.MyOrder)&quot;)
-]]></script>
-</div></div><div class="confluence-information-macro confluence-information-macro-information"><span class="aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>Camel currently only supports either specifying parameter binding or type per parameter in the method name option. You <strong>cannot</strong> specify both at the same time, such as</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[doSomething(com.foo.MyOrder ${body}, boolean ${header.high})
-]]></script>
-</div></div><p>This may change in the future.</p></div></div></div>
+</plain-text-body><p>This is now possible in <strong>Camel 2.9</strong> onwards:</p><plain-text-body>   .bean(OrderService.class, "doSomething(*, true)")
+</plain-text-body><p>In the example above, we defined the first parameter using the wild card symbol *, which tells Camel to bind this parameter to any type, and let Camel figure this out. The 2nd parameter has a fixed value of <code>true</code>. Instead of the wildcard symbol we can instruct Camel to use the message body as shown:</p><plain-text-body>   .bean(OrderService.class, "doSomething(${body}, true)")
+</plain-text-body><p>The syntax of the parameters is using the <a shape="rect" href="simple.html">Simple</a> expression language so we have to use ${ } placeholders in the body to refer to the message body.</p><p>If you want to pass in a <code>null</code> value, then you can explicit define this in the method option as shown below:</p><plain-text-body>   .to("bean:orderService?method=doSomething(null, true)")
+</plain-text-body><p>Specifying <code>null</code> as a parameter value instructs Camel to force passing a <code>null</code> value.</p><p>Besides the message body, you can pass in the message headers as a <code>java.util.Map</code>:</p><plain-text-body>   .bean(OrderService.class, "doSomethingWithHeaders(${body}, ${headers})")
+</plain-text-body><p>You can also pass in other fixed values besides booleans. For example, you can pass in a String and an integer:</p><plain-text-body>   .bean(MyBean.class, "echo('World', 5)")
+</plain-text-body><p>In the example above, we invoke the echo method with two parameters. The first has the content 'World' (without quotes), and the 2nd has the value of 5.<br clear="none"> Camel will automatically convert these values to the parameters' types.</p><p>Having the power of the <a shape="rect" href="simple.html">Simple</a> language allows us to bind to message headers and other values such as:</p><plain-text-body>   .bean(OrderService.class, "doSomething(${body}, ${header.high})")
+</plain-text-body><p>You can also use the OGNL support of the <a shape="rect" href="simple.html">Simple</a> expression language. Now suppose the message body is an object which has a method named <code>asXml</code>. To invoke the <code>asXml</code> method we can do as follows:</p><plain-text-body>   .bean(OrderService.class, "doSomething(${body.asXml}, ${header.high})")
+</plain-text-body><p>Instead of using <code>.bean</code> as shown in the examples above, you may want to use <code>.to</code> instead as shown:</p><plain-text-body>   .to("bean:orderService?method=doSomething(${body.asXml}, ${header.high})")
+</plain-text-body><h3 id="BeanBinding-Usingtypequalifierstoselectamongoverloadedmethods">Using type qualifiers to select among overloaded methods</h3><p><strong>Available as of Camel 2.8</strong></p><p>If you have a <a shape="rect" href="bean.html">Bean</a> with overloaded methods, you can now specify parameter types in the method name so Camel can match the method you intend to use.<br clear="none"> Given the following bean:<plain-text-body>{snippet:id=e1|lang=java|title=MyBean|url=camel/trunk/camel-core/src/test/java/org/apache/camel/component/bean/BeanOverloadedMethodTest.java}</plain-text-body>Then the <code>MyBean</code> has 2 overloaded methods with the names <code>hello</code> and <code>times</code>. So if we want to use the method which has 2 parameters we can do as follows in the Camel route:<plain-text-body>{snippet:id=e2|lang=java|title=Invoke 2 parameter method|url=camel/trunk/camel-core/src/test/java/org/apache/camel/component/bean/BeanOverloadedMethodTest.java}</plain-
 text-body>We can also use a <code>*</code> as wildcard so we can just say we want to execute the method with 2 parameters we do<plain-text-body>{snippet:id=e3|lang=java|title=Invoke 2 parameter method using wildcard|url=camel/trunk/camel-core/src/test/java/org/apache/camel/component/bean/BeanOverloadedMethodTest.java}</plain-text-body>By default Camel will match the type name using the simple name, e.g. any leading package name will be disregarded. However if you want to match using the FQN, then specify the FQN type and Camel will leverage that. So if you have a <code>com.foo.MyOrder</code> and you want to match against the FQN, and <strong>not</strong> the simple name "MyOrder", then follow this example:</p><plain-text-body>   .bean(OrderService.class, "doSomething(com.foo.MyOrder)")
+</plain-text-body><rich-text-body><p>Camel currently only supports either specifying parameter binding or type per parameter in the method name option. You <strong>cannot</strong> specify both at the same time, such as</p><plain-text-body>doSomething(com.foo.MyOrder ${body}, boolean ${header.high})
+</plain-text-body><p>This may change in the future.</p></rich-text-body></div>
         </td>
         <td valign="top">
           <div class="navigation">

Modified: websites/production/camel/content/beanio.html
==============================================================================
--- websites/production/camel/content/beanio.html (original)
+++ websites/production/camel/content/beanio.html Fri Aug 25 09:20:43 2017
@@ -36,17 +36,6 @@
     <![endif]-->
 
 
-  <link href='//camel.apache.org/styles/highlighter/styles/shCoreCamel.css' rel='stylesheet' type='text/css' />
-  <link href='//camel.apache.org/styles/highlighter/styles/shThemeCamel.css' rel='stylesheet' type='text/css' />
-  <script src='//camel.apache.org/styles/highlighter/scripts/shCore.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
-  <script src='//camel.apache.org/styles/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
-  
-  <script type="text/javascript">
-  SyntaxHighlighter.defaults['toolbar'] = false;
-  SyntaxHighlighter.all();
-  </script>
 
     <title>
     Apache Camel: BeanIO
@@ -86,68 +75,12 @@
 	<tbody>
         <tr>
         <td valign="top" width="100%">
-<div class="wiki-content maincontent"><h2 id="BeanIO-BeanIO">BeanIO</h2><p><strong>Available as of Camel 2.10</strong></p><p>The BeanIO <a shape="rect" href="data-format.html">Data Format</a> uses <a shape="rect" class="external-link" href="http://beanio.org/" rel="nofollow">BeanIO</a> to handle flat payloads (such as XML, CSV, delimited, or fixed length formats).</p><p>BeanIO is configured using a <a shape="rect" class="external-link" href="http://beanio.org/2.0/docs/reference/index.html#TheMappingFile" rel="nofollow">mappings XML</a> file where you define the mapping from the flat format to Objects (POJOs). This mapping file is mandatory to use.</p><h3 id="BeanIO-Options">Options</h3><div class="confluenceTableSmall"><div class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p>Option</p></th><th colspan="1" rowspan="1" class="confluenceTh"><p>Default</p></th><th colspan="1" rowspan="1" class="confluenceTh"><p>Description</p>
 </th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>mapping</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The BeanIO mapping file. The option is mandatory. Is by default loaded from the classpath. You can prefix with <code>file:</code>, <code>http:</code>, or <code>classpath:</code> to denote from where to load the mapping file.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>streamName</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The name of the stream to use. This option is mandatory.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>ignoreUnidentifiedRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore unidentified records.</p></td></tr><tr><td colspan="1" 
 rowspan="1" class="confluenceTd"><p>ignoreUnexpectedRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore unexpected records.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>ignoreInvalidRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore invalid records.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>encoding</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Platform default</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The charset to use.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>beanReaderErrorHandler</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>A custom BeanReaderErrorHandler implementa
 tion to use in your dataformat definition</p></td></tr></tbody></table></div></div>
-
-
-<h3 id="BeanIO-Usage">Usage</h3><p>An example of a <a shape="rect" class="external-link" href="https://svn.apache.org/repos/asf/camel/trunk/components/camel-beanio/src/test/resources/org/apache/camel/dataformat/beanio/mappings.xml">mapping file is here</a>.</p><h4 id="BeanIO-UsingJavaDSL">Using Java DSL</h4><p>To use the <code>BeanIODataFormat</code> you need to configure the data format with the mapping file, as well the name of the stream.<br clear="none"> In Java DSL this can be done as shown below. The streamName is "employeeFile".</p><p>Then we have two routes. The first route is for transforming CSV data into a List&lt;Employee&gt; Java objects. Which we then <a shape="rect" href="splitter.html">split</a>, so the mock endpoint<br clear="none"> receives a message for each row.</p><p>The 2nd route is for the reverse operation, to transform a List&lt;Employee&gt; into a stream of CSV data.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelCont
 ent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-// setup beanio data format using the mapping file, loaded from the classpath
-DataFormat format = new BeanIODataFormat(
-        &quot;org/apache/camel/dataformat/beanio/mappings.xml&quot;,
-        &quot;employeeFile&quot;);
-
-// a route which uses the bean io data format to format a CSV data
-// to java objects
-from(&quot;direct:unmarshal&quot;)
-    .unmarshal(format)
-    // and then split the message body so we get a message for each row
-    .split(body())
-        .to(&quot;mock:beanio-unmarshal&quot;);
-
-// convert list of java objects back to flat format
-from(&quot;direct:marshal&quot;)
-    .marshal(format)
-    .to(&quot;mock:beanio-marshal&quot;);
-]]></script>
-</div></div>The CSV data could for example be as below:<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-private static final String FIXED_DATA =
-        &quot;Joe,Smith,Developer,75000,10012009&quot; + LS
-        + &quot;Jane,Doe,Architect,80000,01152008&quot; + LS
-        + &quot;Jon,Anderson,Manager,85000,03182007&quot; + LS;
-]]></script>
-</div></div><h4 id="BeanIO-UsingXMLDSL">Using XML DSL</h4><p>To use the BeanIO data format in XML, you need to configure it using the &lt;beanio&gt; XML tag as shown below. The routes is similar to the example above.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;camelContext xmlns=&quot;http://camel.apache.org/schema/spring&quot;&gt;
-  &lt;!-- setup beanio data format --&gt;
-  &lt;dataFormats&gt;
-    &lt;beanio id=&quot;myBeanio&quot; mapping=&quot;org/apache/camel/dataformat/beanio/mappings.xml&quot; streamName=&quot;employeeFile&quot;/&gt;
-  &lt;/dataFormats&gt;
-
-  &lt;route&gt;
-    &lt;from uri=&quot;direct:unmarshal&quot;/&gt;
-    &lt;unmarshal ref=&quot;myBeanio&quot;/&gt;
-    &lt;split&gt;
-      &lt;simple&gt;body&lt;/simple&gt;
-      &lt;to uri=&quot;mock:beanio-unmarshal&quot;/&gt;
-    &lt;/split&gt;
-  &lt;/route&gt;
-  
-  &lt;route&gt;
-    &lt;from uri=&quot;direct:marshal&quot;/&gt;
-    &lt;marshal ref=&quot;myBeanio&quot;/&gt;
-    &lt;to uri=&quot;mock:beanio-marshal&quot;/&gt;
-  &lt;/route&gt;
-&lt;/camelContext&gt;
-]]></script>
-</div></div><h3 id="BeanIO-Dependencies">Dependencies</h3><p>To use BeanIO in your Camel routes you need to add a dependency on <strong>camel-beanio</strong> which implements this data format.</p><p>If you use Maven you can just add the following to your pom.xml, substituting the version number for the latest &amp; greatest release (see <a shape="rect" href="download.html">the download page for the latest versions</a>).</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;dependency&gt;
+<div class="wiki-content maincontent"><h2 id="BeanIO-BeanIO">BeanIO</h2><p><strong>Available as of Camel 2.10</strong></p><p>The BeanIO <a shape="rect" href="data-format.html">Data Format</a> uses <a shape="rect" class="external-link" href="http://beanio.org/" rel="nofollow">BeanIO</a> to handle flat payloads (such as XML, CSV, delimited, or fixed length formats).</p><p>BeanIO is configured using a <a shape="rect" class="external-link" href="http://beanio.org/2.0/docs/reference/index.html#TheMappingFile" rel="nofollow">mappings XML</a> file where you define the mapping from the flat format to Objects (POJOs). This mapping file is mandatory to use.</p><h3 id="BeanIO-Options">Options</h3><parameter ac:name="class">confluenceTableSmall</parameter><rich-text-body><div class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p>Option</p></th><th colspan="1" rowspan="1" class="confluenceTh"><p>Default</p></th><th colspan="1" rowspan="1
 " class="confluenceTh"><p>Description</p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>mapping</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The BeanIO mapping file. The option is mandatory. Is by default loaded from the classpath. You can prefix with <code>file:</code>, <code>http:</code>, or <code>classpath:</code> to denote from where to load the mapping file.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>streamName</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The name of the stream to use. This option is mandatory.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>ignoreUnidentifiedRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore unidentified r
 ecords.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>ignoreUnexpectedRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore unexpected records.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>ignoreInvalidRecords</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><code>false</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Whether to ignore invalid records.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>encoding</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Platform default</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The charset to use.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>beanReaderErrorHandler</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>A
  custom BeanReaderErrorHandler implementation to use in your dataformat definition</p></td></tr></tbody></table></div></rich-text-body><h3 id="BeanIO-Usage">Usage</h3><p>An example of a <a shape="rect" class="external-link" href="https://svn.apache.org/repos/asf/camel/trunk/components/camel-beanio/src/test/resources/org/apache/camel/dataformat/beanio/mappings.xml">mapping file is here</a>.</p><h4 id="BeanIO-UsingJavaDSL">Using Java DSL</h4><p>To use the <code>BeanIODataFormat</code> you need to configure the data format with the mapping file, as well the name of the stream.<br clear="none"> In Java DSL this can be done as shown below. The streamName is "employeeFile".</p><p>Then we have two routes. The first route is for transforming CSV data into a List&lt;Employee&gt; Java objects. Which we then <a shape="rect" href="splitter.html">split</a>, so the mock endpoint<br clear="none"> receives a message for each row.</p><p>The 2nd route is for the reverse operation, to transform a List
 &lt;Employee&gt; into a stream of CSV data.<plain-text-body>{snippet:id=e1|lang=java|url=camel/trunk/components/camel-beanio/src/test/java/org/apache/camel/dataformat/beanio/BeanIODataFormatSimpleTest.java}</plain-text-body>The CSV data could for example be as below:<plain-text-body>{snippet:id=e2|lang=java|url=camel/trunk/components/camel-beanio/src/test/java/org/apache/camel/dataformat/beanio/BeanIODataFormatSimpleTest.java}</plain-text-body></p><h4 id="BeanIO-UsingXMLDSL">Using XML DSL</h4><p>To use the BeanIO data format in XML, you need to configure it using the &lt;beanio&gt; XML tag as shown below. The routes is similar to the example above.<plain-text-body>{snippet:id=e1|lang=xml|url=camel/trunk/components/camel-beanio/src/test/resources/org/apache/camel/dataformat/beanio/SpringBeanIODataFormatSimpleTest.xml}</plain-text-body></p><h3 id="BeanIO-Dependencies">Dependencies</h3><p>To use BeanIO in your Camel routes you need to add a dependency on <strong>camel-beanio</strong> w
 hich implements this data format.</p><p>If you use Maven you can just add the following to your pom.xml, substituting the version number for the latest &amp; greatest release (see <a shape="rect" href="download.html">the download page for the latest versions</a>).</p><parameter ac:name="">xml</parameter><plain-text-body>&lt;dependency&gt;
   &lt;groupId&gt;org.apache.camel&lt;/groupId&gt;
   &lt;artifactId&gt;camel-beanio&lt;/artifactId&gt;
   &lt;version&gt;2.10.0&lt;/version&gt;
 &lt;/dependency&gt;
-]]></script>
-</div></div></div>
+</plain-text-body></div>
         </td>
         <td valign="top">
           <div class="navigation">

Modified: websites/production/camel/content/book-in-one-page.html
==============================================================================
--- websites/production/camel/content/book-in-one-page.html (original)
+++ websites/production/camel/content/book-in-one-page.html Fri Aug 25 09:20:43 2017
@@ -4368,11 +4368,11 @@ So we completed the last piece in the pi
 <p>This example has been removed from <strong>Camel 2.9</strong> onwards. Apache Axis 1.4 is a very old and unsupported framework. We encourage users to use <a shape="rect" href="cxf.html">CXF</a> instead of Axis.</p></div></div>
 
 <style type="text/css">/*<![CDATA[*/
-div.rbtoc1503649197976 {padding: 0px;}
-div.rbtoc1503649197976 ul {list-style: disc;margin-left: 0px;}
-div.rbtoc1503649197976 li {margin-left: 0px;padding-left: 0px;}
+div.rbtoc1503652754455 {padding: 0px;}
+div.rbtoc1503652754455 ul {list-style: disc;margin-left: 0px;}
+div.rbtoc1503652754455 li {margin-left: 0px;padding-left: 0px;}
 
-/*]]>*/</style><div class="toc-macro rbtoc1503649197976">
+/*]]>*/</style><div class="toc-macro rbtoc1503652754455">
 <ul class="toc-indentation"><li><a shape="rect" href="#BookInOnePage-TutorialusingAxis1.4withApacheCamel">Tutorial using Axis 1.4 with Apache Camel</a>
 <ul class="toc-indentation"><li><a shape="rect" href="#BookInOnePage-Prerequisites">Prerequisites</a></li><li><a shape="rect" href="#BookInOnePage-Distribution">Distribution</a></li><li><a shape="rect" href="#BookInOnePage-Introduction">Introduction</a></li><li><a shape="rect" href="#BookInOnePage-SettinguptheprojecttorunAxis">Setting up the project to run Axis</a>
 <ul class="toc-indentation"><li><a shape="rect" href="#BookInOnePage-Maven2">Maven 2</a></li><li><a shape="rect" href="#BookInOnePage-wsdl">wsdl</a></li><li><a shape="rect" href="#BookInOnePage-ConfiguringAxis">Configuring Axis</a></li><li><a shape="rect" href="#BookInOnePage-RunningtheExample">Running the Example</a></li></ul>

Modified: websites/production/camel/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.