cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicola Ken Barozzi" <>
Subject Content view separation... are we making a mess? ;-)
Date Mon, 18 Sep 2000 16:44:37 GMT
This issue came to mind after writing this to Jeremy:
IMHO, or we have a _standard_ and _safe_ way of passing data from
taglib to taglim ("interface") or none at all.
As I explained to phone to Stefano, let's say you want to draw a chart
from data gotten from sql. You have SGL tags inside CHART tags.
The most linear, logical and Cocoon-like way of doing this is by
writing a Transformer for the chart!
It also gives you the possibility to change chart parameters in the sitemap if you
wish without changing the xml. 
Charting is not data production, it's data transformation.
On the other hand, Transformers are more difficult and less speed some say...
Well for difficulty I wrote a Transformer that can simplify things, and are planning
to make taglibs suitable for transformation (don't hope too much for it guys ;-) ).
As for speed... well to pass data around you need an interface and the SAX
on is concise enough I think... are you sure it's slower? We should test IMO.
And remember: taglibs bloat method size, and for now there's still the 64K limit.

Think now of how Transformers and XSPGenerators work:
XSPGenerators: They get tags from an XML file, elaborate them and
   send them down the pipeline.
Transformers: They get tags from the SAX stream, which comes from a Generator
   that got them from an XML file, elaborate them and  send them down the pipeline.
If we want to separate content and view, we must IMHO have them in two separate
files, as per XSL!
How separate are two tag namespaces in the same file?
Content writers and stylers have to create and update the same file!
What use is a Transformer if a taglib with intra-taglib parameter handling can do
the same, maybe faster?
Many Transformers are there only for coding easiness, not for C-S needs.
IMO this implies that:
- _all_ content should come from Generators, so we should define a standard
  way of taglib result passing.
- all Transformers must get parameters and proper uri tags from other files or sitemap.
- there must be an XSP like way of making transformers and using taglibs in

comments, anyone? :-)


Nicola Ken Barozzi - AISA Industries S.p.A
Via Leonardo da Vinci,2 Ticengo (CR) Italy
Research Activity:
Politecnico di Milano - Dipartimento di Meccanica
Piazza Leonardo da Vinci, n.32 - 20133 Milano (Italy)

View raw message