AFAIK, there as an initiative to use javascript in XSP. But for a lack ofYes, I know. But I dont like XSP. I think XSP is not the best way to integrate logic.
interest there is not fully developed.
For historical reasons flow was introduced with flowscript forYes. But what I want to say is: Why should I use the one language to integrate this logic and the other language to integrate other logic? Why not bring it all together? Why cant I use a JavaScript like an action? Or did you ever seen a car which only can turn left? ;-))
convenience. Later was found the advantages of using Javascript in Flow.
There was hard discusion. You can search cocoon-dev mailarchives about
this topic.
The more different types of integrating logic are possible the more complicated cocoon will become.
To put it all in a nutshell:
I think a solution like this:
<map:match pattern="first"> <map:call function="getValues" return="true"/> <map:transform type="jxt"/> <map:serialize/> </map:match>
is more easier to understand than this:
<map:match pattern="first"> <map:call function="getValues"/> </map:match>
<map:match pattern="second"> <map:generate type="jxt"/> <map:serialize/> </map:match>
ok, this is possible, too:
<map:match pattern="first"> <map:act type="getValues"/> <map:transform type="jxt"/> <map:serialize/> </map:match>
But here I have to use two different languages. In our company we have many html-developers who can use JavaScript but nowone is able to using Java. So we have to realize the simple logic part by the expensive web-developers, too!
Regards Stephan