Sorry, I set the header as and no luck. <setHeader headerName="esc">
<constant>org.apache.velocity.tools.generic.EscapeTool.class</constant> > </setHeader> Thanks Ramesh On Thu, Feb 23, 2012 at 12:01 PM, Ramesh Sridharan <ramesh.sridha...@ihg.com > wrote: > Hi Christian > > I tried setting the header in the SpringDSL like this > > <setHeader headerName="SOAPAction"> > > <constant>org.apache.velocity.tools.generic.EscapeTool.class</constant> > </setHeader> > > and in the template , I used it as > > $headers.esc.xml($headers.addrLine1) > > It did not work. > > Claus, I have created a bundle for velocity tools and deployed it first > before deploying the route bundle. > Also I am importing the package org.apache.velocity.tools.* in the route > bundle pom.xml > > Any other way to get this to work. > > Thanks > Ramesh > > > > > > > On Thu, Feb 23, 2012 at 11:08 AM, Claus Ibsen-2 [via Camel] < > ml-node+s465427n5508489...@n5.nabble.com> wrote: > >> On Thu, Feb 23, 2012 at 4:33 PM, Christian Müller >> <[hidden email] <http://user/SendEmail.jtp?type=node&node=5508489&i=0>> >> wrote: >> > Did you something like >> > exchange.getIn().setHeader("esc", >> > org.apache.velocity.tools.generic.EscapeTool.class); >> > >> > Than you have to use: >> > $headers.esc.xml($headers.addrLine1) >> > >> > Works for us with a custom formatter tool... >> > >> >> How would setting a header with a key "esc" with a value of a .class, >> allow Velocity to know to instantiate and use the EscapeTool ? >> >> Also does this require velocity-tools JAR on the classpath? >> >> If not maybe we can added it by default to camel-velocity? >> >> > Best, >> > Christian >> > >> > On Thu, Feb 23, 2012 at 3:49 PM, ramesri <[hidden >> > email]<http://user/SendEmail.jtp?type=node&node=5508489&i=1>> >> wrote: >> > >> >> Hi Claus >> >> >> >> Please help me out. I am stuck with this and couldnot proceed. >> >> >> >> Thanks >> >> Ramesh >> >> >> >> >> >> -- >> >> View this message in context: >> >> >> http://camel.465427.n5.nabble.com/How-to-use-escape-tool-esc-xml-somestrwithspclchars-in-camel-velocity-template-tp5505668p5508249.html >> >> Sent from the Camel - Users mailing list archive at Nabble.com. >> >> >> >> >> >> -- >> Claus Ibsen >> ----------------- >> FuseSource >> Email: [hidden email]<http://user/SendEmail.jtp?type=node&node=5508489&i=2> >> Web: http://fusesource.com >> Twitter: davsclaus, fusenews >> Blog: http://davsclaus.blogspot.com/ >> Author of Camel in Action: http://www.manning.com/ibsen/ >> >> >> ------------------------------ >> If you reply to this email, your message will be added to the >> discussion below: >> >> http://camel.465427.n5.nabble.com/How-to-use-escape-tool-esc-xml-somestrwithspclchars-in-camel-velocity-template-tp5505668p5508489.html >> To start a new topic under Camel - Users, email >> ml-node+s465427n465428...@n5.nabble.com >> To unsubscribe from Camel - Users, click >> here<http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=465428&code=cmFtZXNoLnNyaWRoYXJhbkBpaGcuY29tfDQ2NTQyOHwxMjE3MTM3MDYz> >> . >> NAML<http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> >> > > -- View this message in context: http://camel.465427.n5.nabble.com/How-to-use-escape-tool-esc-xml-somestrwithspclchars-in-camel-velocity-template-tp5505668p5508700.html Sent from the Camel - Users mailing list archive at Nabble.com.