Tengo el siguiente codigo:
**************************
Options options = new Options(userConfigFile);
Y ESTE CODIGO ME DEVUELVE EL SIGUIENTE ERROR:
java.lang.SecurityException: sealing violation
**************************
Seguimos con el código:
// Creación del JAXP SAXParserFactory y su configuración
SAXParserFactory objFactory = SAXParserFactory.newInstance();
objFactory.setValidating(validation);
System.out.println("Factoria SAX construida y configurada.");
XMLReader objXmlReader = null;
// Creación del JAXP SAXParser
SAXParser objSaxParser = objFactory.newSAXParser();
System.out.println("Parseador SAX construido.");
// Obtiene el SAX XMLReader encapsulado.
objXmlReader = objSaxParser.getXMLReader();
EL ERROR QUE ME DEVUELVE ES EL SIGUIENTE:
java.lang.NoSuchMethodError
Es como si el getXMLReader() no existiera en la clase SAXParser
**************************
Tengo los siguientes comentarios a ver si en algo pueden servir:
- Several people have reported difficulties with Tomcat 4.0b1 when trying to put xerces.jar (or another XML parser) in the WEB-INF/lib directory. In theory, this should work fine -- Tomcat 4.0 implements the new servlet 2.3 recommendation that local classes override ones from the shared library classpath (i.e. all the JAR files in $CATALINA_HOME/lib, which includes the JAXP 1.1 reference implementation required by Jasper).
- JRun Version 3.0 supports the Servlet API Version 2.2 specification for developing server-side components in Java. This includes the concept of Web applications, as defined by the Java Servlet API 2.2 specification. A complete Web application may be composed of Java servlets, JSP pages, static content such as HTML pages, and other application resources. See the JRun Setup Guide for a description of the directory structure for Web applications.
- My guess would be you have more than one DOM implementation on your classpath, and that's the source of the problem.