Hi Neeraj, Thanks for the prompt reply. I had tried this feature. But I am not sure if continue-on-error is same as error-recovery. When we continue on error, the parser does not seem to take the grammar into consideration and hence generates lots of spurious errors. On error recovery I would expect the parser to proceed in a normal fashion. But, you recommend it only at development time as there are no guarantees on normal operation of the parser after a recovery and since it might result in infinite loops.
For example for the following document framgment: <icon > <small-icon>stillTypingMygif <large-icon>/tmp/large.gif</large-icon> </icon> the content model for small-icon has only #PCDATA. I would expect the parser to recover by inserting </small-icon> into the stream before encountering <large-icon>. But the parser recovers by changing </icon> to </small-icon>. This results in cascading spurious errors. How does the error recovery work? Could you give me some pointers as to where I can look for it in the sources? All I could see was that in case of a fatal error if the feature is set, then the saxexception is not propagated. Would appreaciate any suggestions/pointers you can provide. Thanks! Rajiv --- Neeraj Bajaj <[EMAIL PROTECTED]> wrote: > > set the following feature to true. > http://apache.org/xml/features/continue-after-fatal-error > > You should be completely aware of the fact that > there is no guarntee > that parser will behave in normal fashion after > encountering fatal > error. It is advisable to use this feature only > during development time > and NEVER at the production time. XML document > should be corrected as > the first step. Please read the feature > documentation [1] for more detail. > > > [1] http://xml.apache.org/xerces2-j/features.html > > > Neeraj > > __________________________________________________ Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more http://tax.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]