Say, if you attach an error handler to the JAXP validator, then you would recieve validation errors in error handler call-back methods: error, fatalError, or warning
Then, from SAXParseException object you can retrieve error details (which you can write to a file, if you wish). Here are the relevant javadocs: http://xerces.apache.org/xerces2-j/javadocs/api/javax/xml/validation/Validator.html http://xerces.apache.org/xerces2-j/javadocs/api/org/xml/sax/ErrorHandler.html On Tue, Dec 15, 2009 at 5:50 PM, Holger <hle....@googlemail.com> wrote: > Hi, > > Is there a wrapper available for xml schema validation with xerces-j to > write the validation report as a file. There are sample for xerces-j how to > validate via command line? It would be possible the write a batch to put the > console output into a file but I'm looking for a wrapper where you can > define the output uri as a parameter of the command line. Or is there a > wrapper available where a method exist to get the errors as a string, > callable from a java application? > > Greetings > > Hle -- Regards, Mukul Gandhi --------------------------------------------------------------------- To unsubscribe, e-mail: j-users-unsubscr...@xerces.apache.org For additional commands, e-mail: j-users-h...@xerces.apache.org