Incorrect location information on SAX when using XInclude
---------------------------------------------------------

                 Key: XERCESJ-1247
                 URL: https://issues.apache.org/jira/browse/XERCESJ-1247
             Project: Xerces2-J
          Issue Type: Bug
          Components: XInclude 1.0
    Affects Versions: 2.9.0
            Reporter: George Cristian Bina


Hi,

If there is a file that includes another one with xi:include Xerces will report 
to a content handler events from the included file (startElement, characters, 
endElement, etc.). However the locator that is set in the content handler does 
does not report the locations in the included file, instead it remains at the 
xi:include location in the master file.
Looking inside the XIncludeHandler class I see that there is some code that 
tries to deal with this:

        // we do this to ensure that the proper location is reported in errors
        // otherwise, the locator from the root document would always be used
        fErrorReporter.setDocumentLocator(locator);

but the locator is updated only on the error reporter.

The problem is that if one registers a content handler there is no possibility 
to know the location of the notified SAX events.

Thanks,
George

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to