[Saxdotnet-devel] "Unifying" the core and extension interfaces
Brought to you by:
jeffrafter,
kwaclaw
From: Jeff R. <li...@je...> - 2004-12-07 17:16:47
|
"Unifying" the extensions and core interfaces: ============================================== Currently, there are several interfaces marked as extension interfaces. The primary examples are ILexicalHandler and IDeclHandler. These interfaces provide access to data that is not required to be reported by the XML Specification. Hence all of the information is considered "extension" and not "core". That's fine. We don't want to change that. What we do what to change is the clumsy mechanism for connecting extension interfaces to an IXmlReader. Currently this is done through the setproperty/getproperty mechanism. We propose to add new interface level property for LexicalHandler and DeclHandler (that will behave in the same way ContentHandler, ErrorHandler, etc, work). The only difference will be when a parser/implementation does not support the reporting of "extension" data. In such a case, when the property is set the parser can throw a SaxNotSupportedException (or NotSupportedException depending on the outcome of the proposal to change some of the exception design in the API). For those of us that use these interfaces on a regular basis it should simplify a lot of code. Especially when you know about parser/implementation level support a priori. Thanks, Jeff Rafter |