> is there a possibility to redirect a text message > from the element xsl:message to a file instead of > stderr? I validated an xml file against a W3C Schema > and afterwards â in order to do additional checking > â against a stylesheet. The validation errors from > the Xerces parser are written to a file (by use of > a derived class of the DefaultHandler) and I would > like to append the error messages which I defined in > the stylesheet between the <xsl:message> tags to the > already created file. Is there a class for Xalan to > register with the XalanTransformer similar to the > behaviour of the DefaultHandler class?
If you set your own derivative of ProblemListener, using XalanTransformer::setProblemListener(), you can re-direct messages, warnings, and errors. However, you will be responsible for the display of any diagnostic output if you do this. If you just want simple re-direction of warnings and messages, you can set and instance of std::ostream, by calling XalanTranformer::setWarningStream(). Again, this interrupts the normal display of diagnostic output (except errors), so you will be responsible for displaying messages or warnings. Dave
