Hello Stephan,

sorry, but I don't like it that much. It looks like not needed featuritis. The dynamic including can be more than easily and more flexible done with XSLT. Furthermore there can occur non-obvious collisions in the parameter names: The CIncludeTransformer already accepts several parameters.

Please don't take any offense, it's just my opinion.

Regards,

Joerg

On 30.10.2003 17:12, Stephan Coboos wrote:

Hello,

because I needed a CIncludeTransformer which is able to include dynamically
resources, I had modificated the CIncludeTransformer a little bit. Now its
possible to pass sitemap parameters to the transformer. Within the src
attribute the variable will be replaced by the value of the parameter. Does
anyone need this feature, too?

For example:

somefile.xml:

<element ...>
    <...:include src="cocoon:/{filename}"/>
</element>

pipeline:

...
<map:transform type="cinclude">
    <map:parameter name="filename" value="myFile.xml"/>
</map:transform>
...

Result:

<element ...>
    <...:include src="cocoon:/myFile.xml"/>
</element>

Regards
Stephan



Reply via email to