Force using Xerces instead of Java's built-in classes ?
lionel laffineur
Greenhorn
Posts: 8
Jimmy Clark
Ranch Hand
Posts: 2187
posted 14 years ago
-
-
Number of slices to send:Optional 'thank-you' note:
-
-
Keep in mind that there is a version of Xerces that has been incorprated into the JRE as of version 1.4.
If you want to use the faster Apache version of Xerces, then you need to specify the classname of the SAXParser which is in your imported Xerces library. You do this when creating the XMLReader object.
If you want to use the faster Apache version of Xerces, then you need to specify the classname of the SAXParser which is in your imported Xerces library. You do this when creating the XMLReader object.
lionel laffineur
Greenhorn
Posts: 8
posted 14 years ago
-
-
Number of slices to send:Optional 'thank-you' note:
-
-
I'm using this peace of code:
How can I specify which parser must be used ?
1 2 3 | DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); Document doc = db.parse(xmlFile); |
How can I specify which parser must be used ?
Jimmy Clark
Ranch Hand
Posts: 2187
posted 14 years ago
-
-
Number of slices to send:Optional 'thank-you' note:
-
-
If you are using DOM-based API, then you most likely will not have the ability to specify the classname of the SAXParser.
You might however. This feature might be exposed in the DOM implementation that you are using.
You might however. This feature might be exposed in the DOM implementation that you are using.
Let nothing stop you! Not even this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|