This section contains information you need to know to prepare your system to use the JDBC driver XML methods.
To use the XML methods, add the pathnames of the following files to your CLASSPATH setting:
All of these files are located in the lib directory where you installed your driver.
The XML methods are not part of the ifxjdbc.jar file. Instead, they are released in a separate .jar file named ifxtools.jar. To use the methods, you must add this file to your CLASSPATH setting along with ifxjdbc.jar.
In addition, building ifxtools.jar requires using code from a .jar file that supports the SAX, DOM, and JAXP methods. To use ifxtools.jar, you must add these .jar files to your CLASSPATH setting.
JDK version 1.4 or later uses the Sun Microsystems default XML parser even if the xml4j parser is in the CLASSPATH. To use the xml4j implementation of the SAX parser, set the following system properties in the application code or use the -D command line option:
For more info on how to set the properties see Specifying a Parser Factory.
By default, the xml4j xerces parser (and as a result, ifxtools.jar) uses the non-validating XML parser. To use an alternative SAX parser factory, run your application from the command line as follows:
% java -Djavax.xml.parsers.SAXParserFactory=new-factory
If you are not running from the command line, the factory name must be enclosed in double quotes:
% java -Djavax.xml.parsers.SAXParserFactory="new-factory"
You can also set a system property in your code:
System.setProperty("javax.xml.parsers.SAXParserFactory",
"new-factory")
In this code, new-factory is the alternative parser factory. For example, if you are using the xerces parser, then new-factory is replaced by org.apache.xerces.jaxp.SAXParserFactoryImpl.
It is also possible to use an alternative document factory for DOM methods. Run your application from the command line as follows:
% java -Djavax.xml.parsers.DocumentBuilderFactory=new-factory
If you are not running from the command line, the factory name must be enclosed in double quotes:
% java -Djavax.xml.parsers.DocumentBuilderFactory="new-factory"
You can also set a system property in your code:
System.setProperty("javax.xml.parsers.DocumentBuilderFactory",
"new-factory")
For example, if you are using the xerces parser, then new-factory is replaced by jorg.apache.xerces.jaxp.DocumentBuilderFactoryImpl.
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]