Ivelin Ivanov wrote:

>This question is targeted to the commiters who are actively maintaining
>
>org.apache.avalon.excalibur.xml.xslt.XSLTProcessorImpl
>and
>org.apache.cocoon.transformation.TraxTransformer
>
>I've noticed that neither uses the javax.xml.transform.ErrorListener class
>to register as listener to the Transformer, so that XSLT processing errors
>can
>be reported with details ( ErrorListener.getMessageAndLocation() ) in the
>browser window when the stylesheet being processed is bad.
>
>I believe most of us will agree that accurate error reporting is important
>for the most widely used transformer in Cocoon.
>
>
>Before I start I would appreciate some direction.
>I have not dealt with the TraxTransformer to date and therefore any guidance
>as to where I should focus to introduce this improvement will be
>appreciated.
>
Ivelin, you should look at o.a.c.xml.TraxErrorHandler, which implements 
ErrorListener and is used in TraxTransformerImpl.

I studied this a while ago, and IIRC there was a problem with 
<xsl:message terminate=true> which calls the ErrorListener with an 
exception containing the message and terminates the processing with 
another one (catched by TraxTransformerImpl) which only states 
"stylesheet directed termination". Maybe the exception passed to the 
ErrorListener should be buffered to be rethrown at the end of processing.

Sylvain

-- 
Sylvain Wallez
 Anyware Technologies                  Apache Cocoon
 http://www.anyware-tech.com           mailto:[EMAIL PROTECTED]




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

Reply via email to