RE: [xsl] XMLFilter in a URIResolver

Subject: RE: [xsl] XMLFilter in a URIResolver
From: "Andrew Welch" <AWelch@xxxxxxxxxxxxxxx>
Date: Thu, 11 Sep 2003 15:48:12 +0100
> When you supply a SAXSource to Saxon, Saxon sets the properties of the
> XMLReader supplied with the SAXSource to make sure that it is
reporting
> namespaces in the way that Saxon requires. Specifically it does:
> 
>      	parser.setFeature("http://xml.org/sax/features/namespaces";,
> true);
> 
> parser.setFeature("http://xml.org/sax/features/namespace-prefixes";,
> false);
> 
> A SAX2 parser is expected to recognize these properties; if it
responds
> to these requests with an exception, Saxon complains with the error
> message that you saw.
> 
> Your XMLFilter is pretending to be a SAX2 parser, so it must support
> these methods properly.

Ok... does that mean I should write a no-op setFeature method in my
XMLFilter to stop the error message, and then modify my startElement()
call to match that of a parser with those features set?

Currently I get the error: 

org.xml.sax.SAXNotRecognizedException: Feature:
http://xml.org/sax/features/namespaces

Do I need to use setFeature() on something other that the XMLFilter?  Or
do I need to modify the startElement() call to look at though the
features are set?  If I need to modify the startElement() call, how
would it look when there aren't any namespace involved (as in, it would
look exactly the same wouldn't it?)

Thanks for the continued help 

andrew


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread