On 18.06.2004 09:18, [EMAIL PROTECTED] wrote:

Removing the surplus namespace afterwards is what I am doing right now.
My idea was to avoid it by configuring CincludeTransformer instead of having an extra step for just only stripping namespace after transformation.

Though it should be possible to filter out this particular namespace declaration it can lead to invalid XML, when you have additional elements in the cinclude namespace that are not handled by cincludetransformer. Additionally the namespace handling is a very dangerous field for such optimizations as it is highly processor and processor version dependent, so Cocoon has to take care for the weakest one.

I clearly understand that CincludeTransformer needs cindlude namespace in the _input_ to recognize the elements to be processed. But as CincludeTransformer during transformation completely replaces those elements with the cincluded content, I don't see any reason why cinclude namespace should be copied to the _output_.

It replaces only those elements in the cinclude namespace that are known to it, e.g. cinclude:include, but not cinclude:xyz. If you remove the namespace declaration for cinclude though there can still be those unknown elements in cinclude namespace in the output, you have invalid XML. Of course you can also find out if there are such unknown elements in cinclude namespace, but to remove the namespace declaration only on demand needs buffering of the whole SAX stream and this would result in a performance drawback.


Joerg

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to