The SAX 2 documentation states in the API docs for XMLReader:
public void parse(java.lang.String systemId) throws java.io.IOException, SAXException
Parse an XML document from a system identifier (URI).
This method is a shortcut for the common case of reading a document from a system identifier. It is the exact equivalent of the following:
parse(new InputSource(systemId));
Notice the phrase "exact equivalent". Either that statement is too strong or Xerces does not properly implement this method in XMLFilterImpl. In Xerces in the XMLFilterImpl class the parse(systemId) method is defined as follows:
public void parse (String systemId) throws SAXException, IOException { setupParse(); parent.parse(systemId); }
The result is that overriding parse(InputSource in) in a subclass of XMLFilterImpl does not change the behavior of parse(String systemId) so they are not exactly equivalent. What I suspect it should do is:
public void parse (String systemId) throws SAXException, IOException { parse(new InputSource(systemId)); }
Xerces does seem to do the right thing in XMLParser so this problem only manifests itself if you're subclassing XMLFilterImpl and overriding only one of the two parse() methods.
+-----------------------+------------------------+-------------------+ | Elliotte Rusty Harold | [EMAIL PROTECTED] | Writer/Programmer | +-----------------------+------------------------+-------------------+ | The XML Bible (IDG Books, 1999) | | http://metalab.unc.edu/xml/books/bible/ | | http://www.amazon.com/exec/obidos/ISBN=0764532367/cafeaulaitA/ | +----------------------------------+---------------------------------+ | Read Cafe au Lait for Java News: http://metalab.unc.edu/javafaq/ | | Read Cafe con Leche for XML News: http://metalab.unc.edu/xml/ | +----------------------------------+---------------------------------+