RE: [xml] Error handling with the XmlReader API

  Yep, I assume you tried to match the names of the accessors for the
Locators with those at the xmlTextReader level (can't 
remember I switched
work to something else, the reader is a bit out of context ATM).

Right, here is the patch.

- the opaque xmlTextReaderLocator is in
- I've mimicked parts of errors.c to skip some validation errors
  that are not significant (because they contain only locator 
  info), and I've attempted to find the correct filename and 
  line number (maybe you should have a look at 
  xmlTextReaderLocatorLineNumber and xmlTextReaderLocatorBaseURI)
- the new exports are in libxml2.def.src

python bindings:
- new xmlTextReaderLocator wrapper class
- xmlTextReader error callbacks now accept (arg,msg,severity,locator)
- xmlParserCtxt error handling has been cleaned up and is now
  closer to xmlTextReader error handling (single callback with severity);
  there is a reserved argument to the callback for the locator
  but it's not implemented yet (it needs a bit more thought)
- tests are adapted
- new error handling with Locator, and an IsEmptyElement bug fix ;-(


Attachment: ctxerr.patch
Description: Binary data

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]