You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by bu...@apache.org on 2002/07/09 19:50:55 UTC

DO NOT REPLY [Bug 10603] New: - Allow extension to return SAX events?

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10603>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10603

Allow extension to return SAX events?

           Summary: Allow extension to return SAX events?
           Product: XalanJ2
           Version: CurrentCVS
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: org.apache.xalan.extensions
        AssignedTo: xalan-dev@xml.apache.org
        ReportedBy: keshlam@us.ibm.com


Just got a request from someone who'd like to avoid generating DOM fragments, 
and would prefer to pass us a series of SAX events to be included into the 
output stream. This has obvious hazards (a DOM tree enforces a certain amount of 
consistancy that a SAX stream doesn't) but I can see a possible efficiency 
argument.

Two possible approaches:

1) Allow extensions to return a SAXSource (or XMLReader), which we would then 
connect up and invoke to drive its output into our stream.

2) Allow extensions to request a listener that they could deliver events to. 
That'd be much simpler for extensions which just want to produce a bit of 
hardcoded structure, in-line. (I think it's actually possible to do this now by 
delivering events directly to the transformer's result tree handler... but that 
isn't tested or documented, and there may be questions of when this occurs 
versus other events in the vicinity of the extension.)

May be too hazardous, but worth a closer look.