You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by jk...@apache.org on 2001/10/22 23:13:19 UTC
cvs commit: xml-xalan/java/src/org/apache/xml/dtm/ref IncrementalSAXSource_Xerces.java
jkesselm 01/10/22 14:13:19
Modified: java/src/org/apache/xml/dtm/ref
IncrementalSAXSource_Xerces.java
Log:
In Xerces2, SAXParser no longer seems to inherit from
XMLReader; explicit casts needed to work around that.
Revision Changes Path
1.5 +6 -2 xml-xalan/java/src/org/apache/xml/dtm/ref/IncrementalSAXSource_Xerces.java
Index: IncrementalSAXSource_Xerces.java
===================================================================
RCS file: /home/cvs/xml-xalan/java/src/org/apache/xml/dtm/ref/IncrementalSAXSource_Xerces.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- IncrementalSAXSource_Xerces.java 2001/10/18 12:57:51 1.4
+++ IncrementalSAXSource_Xerces.java 2001/10/22 21:13:19 1.5
@@ -157,7 +157,9 @@
// Register handler directly with the incremental parser
public void setContentHandler(org.xml.sax.ContentHandler handler)
{
- fIncrementalParser.setContentHandler(handler);
+ // Typecast required in Xerces2; SAXParser doesn't inheret XMLReader
+ // %OPT% Cast at asignment?
+ ((XMLReader)fIncrementalParser).setContentHandler(handler);
}
// Note name, needed to dodge the inherited Xerces setLexicalHandler
@@ -167,7 +169,9 @@
// Not supported by all SAX2 parsers but should work in Xerces:
try
{
- fIncrementalParser.setProperty("http://xml.org/sax/properties/lexical-handler",
+ // Typecast required in Xerces2; SAXParser doesn't inheret XMLReader
+ // %OPT% Cast at asignment?
+ ((XMLReader)fIncrementalParser).setProperty("http://xml.org/sax/properties/lexical-handler",
handler);
}
catch(org.xml.sax.SAXNotRecognizedException e)
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org