cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Fagerstrom <dani...@nada.kth.se>
Subject Re: svn commit: r159314 - in cocoon/trunk/src/test/org/apache/cocoon: environment/mock/ generation/ generation/sub/
Date Tue, 29 Mar 2005 09:36:14 GMT
Vadim Gritsenko wrote:

> danielf@apache.org wrote:
>
>> +      <map:generator name="virtual3" 
>> src="org.apache.cocoon.generation.VirtualPipelineGenerator">
>> +        <map:source param="source"/>
>> +        <map:generate type="jx" src="vpc-source-param.xml">
>> +           <map:parameter name="source" value="{source}"/>
>> +           <map:parameter name="foo2" value="{foo}"/>
>> +        </map:generate>
>> +      </map:generator>
>
>
> I don't remember this (map:generator/map:source) discussed anywhere - 
> can you point me to the correct mail?

> Element map:source was only mentioned once in the context of 
> map:generate, and -1.
>
> Vadim

It's not discussed anywhere so we can start now ;)

First Sylvain points out in 
http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=110064557022481&w=2 
that it must be the responsibility of the definition of the VPC to 
declare which parameters that are sources rather than the responsibility 
of the caller. Second he proposes that they should be declared with, 
map:absolutize, e.g.

<map:generator name="foo">
  <map:absolutize param="src"/>
  <map:absolutize param="bar"/>

  <map:generate type="file" src="{src}">
    <map:parameter name="baz" value="bar"/>
  </map:parameter>
  <map:transform src="data/{skin}.xslt/>
</map:generator>

I describe why I don't like the particular absolutize idea in 
http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=110539791029866&w=2, 
the reason is that it breaks isolation between caller and callee and 
doesn't work well with my vision about how blocks should work. So I 
used  map:source instead as it is implementation neutral. But we can of 
course change it to something else if you have better suggestions.

/Daniel


Mime
View raw message