Modified: websites/production/camel/content/book-languages-appendix.html
==============================================================================
--- websites/production/camel/content/book-languages-appendix.html (original)
+++ websites/production/camel/content/book-languages-appendix.html Thu Sep 14 
19:25:46 2017
@@ -164,7 +164,7 @@ from("activemq:topic:OrdersTopic&qu
 ]]></script>
 </div></div><h3 
id="BookLanguagesAppendix-Dependencies.1">Dependencies</h3><p>The Constant 
language is part of <strong><code>camel-core</code></strong>.</p> 
 <h2 id="BookLanguagesAppendix-EL">EL</h2><p>Camel supports the unified JSP and 
JSF Expression Language via the <a shape="rect" class="external-link" 
href="http://juel.sourceforge.net/"; rel="nofollow">JUEL</a> to allow an <a 
shape="rect" href="expression.html">Expression</a> or <a shape="rect" 
href="predicate.html">Predicate</a> to be used in the <a shape="rect" 
href="dsl.html">DSL</a> or <a shape="rect" href="xml-configuration.html">Xml 
Configuration</a>.</p><p>For example you could use EL inside a <a shape="rect" 
href="message-filter.html">Message Filter</a> in XML</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;route&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[&lt;route&gt;
   &lt;from uri=&quot;seda:foo&quot;/&gt;
   &lt;filter&gt;
     &lt;el&gt;${in.headers.foo == &#39;bar&#39;}&lt;/el&gt;
@@ -173,7 +173,7 @@ from(&quot;activemq:topic:OrdersTopic&qu
 &lt;/route&gt;
 ]]></script>
 </div></div><p>You could also use slightly different syntax, e.g. if the 
header name is not a valid identifier:</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;route&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[&lt;route&gt;
   &lt;from uri=&quot;seda:foo&quot;/&gt;
   &lt;filter&gt;
     &lt;el&gt;${in.headers[&#39;My Header&#39;] == &#39;bar&#39;}&lt;/el&gt;
@@ -413,7 +413,7 @@ result = body * 2 + 1
 <p>Or the something like this in your Spring XML:</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[
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[
 &lt;filter&gt;
   &lt;language 
language=&quot;beanshell&quot;&gt;request.getHeaders().get(&quot;Foo&quot;) == 
null&lt;/language&gt;
   ...
@@ -466,7 +466,7 @@ result = body * 2 + 1
 
 <p>And a Spring DSL sample as well:</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[
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[
     &lt;route&gt;
         &lt;from uri=&quot;direct:start&quot;/&gt;
         &lt;choice&gt;
@@ -515,7 +515,7 @@ result = body * 2 + 1
 from(&quot;queue:foo&quot;).filter(groovy(&quot;request.lineItems.any { i 
-&gt; i.value &gt; 100 }&quot;)).to(&quot;queue:bar&quot;)
 ]]></script>
 </div></div><p>And the Spring DSL:</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;route&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[        &lt;route&gt;
             &lt;from uri=&quot;queue:foo&quot;/&gt;
             &lt;filter&gt;
                 &lt;groovy&gt;request.lineItems.any { i -&gt; i.value &gt; 100 
}&lt;/groovy&gt;
@@ -547,7 +547,7 @@ result = body * 2 + 1
             .to(&quot;seda:regularQueue&quot;);
 ]]></script>
 </div></div><p>And a Spring DSL sample as well:</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;route&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[    &lt;route&gt;
         &lt;from uri=&quot;direct:start&quot;/&gt;
         &lt;choice&gt;
             &lt;when&gt;
@@ -628,7 +628,7 @@ result = body * 2 + 1
 
 <p>And a Spring DSL sample as well:</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[
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[
     &lt;route&gt;
         &lt;from uri=&quot;direct:start&quot;/&gt;
         &lt;choice&gt;
@@ -806,7 +806,7 @@ simple("${in.header.type} == ${bean:orde
 <script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[fileName=&quot;uniquefile-${bean:myguidgenerator.generateid}.txt&quot;
 ]]></script>
 </div></div><p>And of course all this can be combined in one expression where 
you can use the <a shape="rect" href="file-language.html">File Language</a>, <a 
shape="rect" href="simple.html">Simple</a> and the <a shape="rect" 
href="bean.html">Bean</a> language in one combined expression. This is pretty 
powerful for those common file path patterns.</p><h3 
id="BookLanguagesAppendix-UsingSpring'sPropertyPlaceholderConfigurerwiththeFileComponent">Using
 Spring's&#160;<code>PropertyPlaceholderConfigurer</code> with the <a 
shape="rect" href="file2.html">File</a> Component</h3><p>In Camel you can use 
the <a shape="rect" href="file-language.html">File Language</a> directly from 
the <a shape="rect" href="simple.html">Simple</a> language which makes a <a 
shape="rect" href="content-based-router.html">Content Based Router</a> easier 
to do in Spring XML, where we can route based on file extensions as shown 
below:</p><div class="code panel pdl" style="border-width: 1px;"><div 
class="codeContent pan
 elContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[&lt;from 
uri=&quot;file://input/orders&quot;/&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[&lt;from 
uri=&quot;file://input/orders&quot;/&gt;
   &lt;choice&gt;
     &lt;when&gt;
       &lt;simple&gt;${file:ext} == &#39;txt&#39;&lt;/simple&gt;
@@ -842,7 +842,7 @@ Could not resolve placeholder &#39;date:
 ]]></script>
 </div></div><h3 
id="BookLanguagesAppendix-Dependencies.16">Dependencies</h3><p>The File 
language is part of <strong><code>camel-core</code></strong>.</p> 
 <h2 id="BookLanguagesAppendix-SQLLanguage">SQL Language</h2><p>The SQL support 
is added by <a shape="rect" class="external-link" 
href="http://josql.sourceforge.net/"; rel="nofollow">JoSQL</a> and is primarily 
used for performing SQL queries on in-memory objects. If you prefer to perform 
actual database queries then check out the <a shape="rect" 
href="jpa.html">JPA</a> component.</p><div class="confluence-information-macro 
confluence-information-macro-tip"><p class="title">Looking for the SQL 
component</p><span class="aui-icon aui-icon-small aui-iconfont-approve 
confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>Camel has both a <a shape="rect" 
href="sql.html">SQL</a> language and a <a shape="rect" 
href="sql-component.html">SQL Component</a>. This page is about the SQL 
language. Click on <a shape="rect" href="sql-component.html">SQL Component</a> 
if you are looking for the component instead.</p></div></div><p>To use SQL in 
your camel routes you
  need to add the a dependency on <strong>camel-josql</strong> which implements 
the SQL language.</p><p>If you use maven you could 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;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[&lt;dependency&gt;
   &lt;groupId&gt;org.apache.camel&lt;/groupId&gt;
   &lt;artifactId&gt;camel-josql&lt;/artifactId&gt;
   &lt;version&gt;x.x.x&lt;/version&gt;
@@ -853,7 +853,7 @@ Could not resolve placeholder &#39;date:
 <script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[from(&quot;queue:foo&quot;).setBody().sql(&quot;select
 * from MyType&quot;).to(&quot;queue:bar&quot;)
 ]]></script>
 </div></div><p>And the spring DSL:</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;from uri=&quot;queue:foo&quot;/&gt;
+<script class="brush: java; gutter: false; theme: Default" 
type="syntaxhighlighter"><![CDATA[   &lt;from uri=&quot;queue:foo&quot;/&gt;
    &lt;setBody&gt;
        &lt;sql&gt;select * from MyType&lt;/sql&gt;
    &lt;/setBody&gt;


Reply via email to