The Error Listener |
The Error Listener receives notification of all warnings and errors (whether recoverable or not) generated when compiling the stylesheet, or produced by the XM_XSLT_TRANSFORMER.
XSLT defines some errors as recoverable (and specifies optional recovery options), and others as non-recoverable. Conditions not defined by XSLT are raised by the library as warnings.
The following features may be of interest to the Eiffel programmer:
If it evaluates to Recover_with_warnings, then it should additionally inform the user of the recovered condition, provided recoverable_error_threshold has not been exceeded (although it is not obliged to honour this threshold).
If, however, it evaluates to Do_not_recover, then it should inform the user of the error condition, and set recovered to False.
This routine must set recovered to True if it recovers from an error, so that the transformer can take the defined recovery action.
If the error listener exposes the error code (and its namespace uri) in any way, then it must honour the error_change_stack. See XM_XSLT_DEFAULT_ERROR_LISTENER for how to do this. It may be necessary to copy the error location information.
If the error listener exposes the error code (and its namespace uri) in any way, then it must honour the error_change_stack. See XM_XSLT_DEFAULT_ERROR_LISTENER for how to do this. It may be necessary to copy the error location information.
This is the chief concrete error listener provided by the library. It maintains error counts. The recovery policy is passed as an argument to the creation routine, as also is a UT_ERROR_HANDLER to receive the warning and error messages.
This error listener supresses all output, but records which error message codes it has seen. It was written for use in the XSLT test suite, so as to avoid confusing the user by displaying error messages which are intentionally being produced.
Copyright © 2004-2016, Colin Adams and others mailto:colin@colina.demon.co.uk http://www.gobosoft.com Last Updated: 27 December 2016 |