Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-11-02 Thread Daniel Fagerstrom
Sylvain Wallez wrote: Carsten Ziegeler wrote: Sylvain Wallez wrote: XPath is a must-have when you deal with XML documents while Jexl is mostly useless in that case but is straightforward when you deal with JavaBeans. I also agree that understanding the difference between ${continuation.id} and

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-11-02 Thread Antonio Gallardo
Daniel Fagerstrom dijo: I agree with Sylvain. I mainly use expression languages for accessing DOM trees, and we write a lot of XSLT at my company, so for us JXPath (or other XPath based expression languages) is the natural choice. For people who mainly work in Java, and use Cocoon as a view

Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Sylvain Wallez
Carsten Ziegeler wrote: Sylvain Wallez wrote: XPath is a must-have when you deal with XML documents while Jexl is mostly useless in that case but is straightforward when you deal with JavaBeans. I also agree that understanding the difference between ${continuation.id} and

RE: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Carsten Ziegeler
Sylvain Wallez wrote: That's exactly what I suggest above: we choose a standard default language, but open the possibility to plug in new ones. XPath is a must-have, Jexl and IM have very valid use cases which IMO justify them to be provided by Cocoon. Other languages are just a

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Leszek Gawron
Carsten Ziegeler wrote: Sylvain Wallez wrote: That's exactly what I suggest above: we choose a standard default language, but open the possibility to plug in new ones. XPath is a must-have, Jexl and IM have very valid use cases which IMO justify them to be provided by Cocoon. Other languages

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Sylvain Wallez
Carsten Ziegeler wrote: Sylvain Wallez wrote: That's exactly what I suggest above: we choose a standard default language, but open the possibility to plug in new ones. XPath is a must-have, Jexl and IM have very valid use cases which IMO justify them to be provided by Cocoon. Other

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Vadim Gritsenko
Sylvain Wallez wrote: Carsten Ziegeler wrote: Sylvain Wallez wrote: That's exactly what I suggest above: we choose a standard default language, but open the possibility to plug in new ones. XPath is a must-have, Jexl and IM have very valid use cases which IMO justify them to be provided by

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Bertrand Delacretaz
Le 29 oct. 04, à 15:05, Vadim Gritsenko a écrit : Sylvain Wallez wrote: ...Technically this should be possible, but how do we write something like widget.getChild(foo).getAttribute(bar) in XPath? Tecnically, this will be getAttribute(getChild($widget, foo), bar) in JXPath. Not exactly easy to

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Sylvain Wallez
Vadim Gritsenko wrote: Sylvain Wallez wrote: Carsten Ziegeler wrote: What can you do with Jexl what you can't do with an XPath based language? My understanding is that they only differ in their syntax ('.' instead of '/'). Now even if Jexl has more functionality I don't see a reason why this

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Vadim Gritsenko
Bertrand Delacretaz wrote: Le 29 oct. 04, à 15:05, Vadim Gritsenko a écrit : Sylvain Wallez wrote: ...Technically this should be possible, but how do we write something like widget.getChild(foo).getAttribute(bar) in XPath? Tecnically, this will be getAttribute(getChild($widget, foo), bar) in

RE: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Bart Molenkamp
-Original Message- From: Vadim Gritsenko [mailto:[EMAIL PROTECTED] Bertrand Delacretaz wrote: Le 29 oct. 04, à 15:05, Vadim Gritsenko a écrit : Sylvain Wallez wrote: ...Technically this should be possible, but how do we write something like

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Sylvain Wallez
Vadim Gritsenko wrote: Bertrand Delacretaz wrote: Le 29 oct. 04, à 15:05, Vadim Gritsenko a écrit : Sylvain Wallez wrote: ...Technically this should be possible, but how do we write something like widget.getChild(foo).getAttribute(bar) in XPath? Tecnically, this will be

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Bertrand Delacretaz
Le 29 oct. 04, à 15:51, Sylvain Wallez a écrit : Vadim Gritsenko wrote: Bertrand Delacretaz wrote: ... And technically in plain XPath it would be something like //widget/foo/@bar IIUC, JXPath has pluggable introspectors, so it above can be reduced to: $widget/foo/@bar Eeek. Do you really

RE: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Bart Molenkamp
I don't know if I'm right here, but... - For java objects, Jexl can do more than JXPath. - For DOM trees, JXPath is better (readible). Maybe it's a good idea to configure the expression language you want to use? E.g. in the configuration of the JXTG, or maybe passing it as a parameter in

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Sylvain Wallez
Bertrand Delacretaz wrote: Le 29 oct. 04, à 15:51, Sylvain Wallez a écrit : Vadim Gritsenko wrote: Bertrand Delacretaz wrote: ... And technically in plain XPath it would be something like //widget/foo/@bar IIUC, JXPath has pluggable introspectors, so it above can be reduced to:

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Vadim Gritsenko
Bertrand Delacretaz wrote: Le 29 oct. 04, à 15:51, Sylvain Wallez a écrit : Vadim Gritsenko wrote: Bertrand Delacretaz wrote: ... And technically in plain XPath it would be something like //widget/foo/@bar IIUC, JXPath has pluggable introspectors, so it above can be reduced to:

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Bertrand Delacretaz
Le 29 oct. 04, à 17:20, Vadim Gritsenko a écrit : ..But we were talking about getChild(foo)... got it now - thanks ;-) -Bertrand smime.p7s Description: S/MIME cryptographic signature

Re: Expression languages (was Re: [RT] StringTemplate: The answer to our templating needs?)

2004-10-29 Thread Stefano Mazzocchi
Sylvain Wallez wrote: Carsten Ziegeler wrote: Sylvain Wallez wrote: XPath is a must-have when you deal with XML documents while Jexl is mostly useless in that case but is straightforward when you deal with JavaBeans. I also agree that understanding the difference between ${continuation.id}