Daniel Fagerstrom wrote:
Joerg Heinicke wrote:

Hello,

I was asked for a possible refactoring of the JXTemplateGenerator. Somebody wants to provide only a very limited set of functionality to his template writers: only JXPath (no JEXL), only one object model.

He started with patching the version of JXTemplateGenerator coming with 2.1.7. Simply extending it does not work because of to much private stuff. But with the refactoring happened to the official JXTemplateGenerator this also seems not to make much sense.


Redoing the refactoring work that Leszek and I already have done seem like wasting time.

Now the questions: The refactoring happened only in the trunk, didn't it?


It only happened in trunk, keeping a synchronized copy in the 2.1.x branch while refactoring didn't seem that fun. It would probably easy to port it to 2.1.x if anyone feel like doing it.
The only problem is the object model that changed a little bit (this makes one of the test cases fail in trunk).

To make the expressions completely plugable within the template framework, we need a expression parser interface and we need to make the expression parser implementation plugable in the Parser.
Plugging one expression parser into the Parser is not enough. Most of users will still want to use both JEXL and JXPath in one template as the functionality of both maps well on different areas of object model.

I'll read previous discussions again and try to implement something both pluggable and convertor ready.


Is there any obvious problem using the template block in Cocoon 2.1?


No.
Nope.


                  --- o0o ---

Further links about the template block design and discussions can be found at http://wiki.apache.org/cocoon/Templates. There was also an agreement that JXTG should be renamed to CTemplate and get a new name space. We had some discussion about what CTemplate should contain: http://marc.theaimsgroup.com/?t=110942300500004&r=1&w=2. Among other things it was supposed to have more plugable expressions.

/Daniel


--
Leszek Gawron                                      [EMAIL PROTECTED]
IT Manager                                         MobileBox sp. z o.o.
+48 (61) 855 06 67                              http://www.mobilebox.pl
mobile: +48 (501) 720 812                       fax: +48 (61) 853 29 65

Reply via email to