Re: Java DSL / GroovyExpression / Binding

2013-08-23 Thread Claus Ibsen
You are welcome to provide patches and improve the groovy dsl. We love contributions http://camel.apache.org/contributing.html On Mon, Aug 19, 2013 at 8:52 AM, mailingl...@j-b-s.de mailingl...@j-b-s.de wrote: Hi Willem, thanks for your answer, unfortunately overriding eval is not sufficient as

Re: Java DSL / GroovyExpression / Binding

2013-08-19 Thread Willem jiang
Hi, You don't need to copy the class, you can just override the evaluate method to setup the binding as you want. -- Willem Jiang Red Hat, Inc. Web: http://www.redhat.com Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English) http://jnn.iteye.com

Re: Java DSL / GroovyExpression / Binding

2013-08-19 Thread mailingl...@j-b-s.de
Hi Willem, thanks for your answer, unfortunately overriding eval is not sufficient as this method initializes everything and calls several private methods. By copy I meant: new ctor, copy eval, copy instantiateScript and copy createBinding to make it work which feels wrong. Furthermore my

Java DSL / GroovyExpression / Binding

2013-08-18 Thread mailingl...@j-b-s.de
Hi all! Is there any chance to extend the binding of a GroovyExpression? Currently (in camel 2.11.1) the Groovy binding is defined on runtime based on the exchange only and I did not find an extension point. My current solutions is to use a GroovyExpression2 class which is a copy of the