You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by William Lee <wl...@sendmail.com> on 2001/03/06 21:58:37 UTC

LinkageError when you do a DOM to DOM transformation

I've tried to follow the Xalan sample DOM2DOM but I got into this
java.lang.LinkageError.  It seems like there is something wrong when
loading the org/w3m/dom/Node class with "loader constraints violated" in
the following code:

		... Some other init stuff, where dBuilder is the DocumentBuilder
                Document doc = dBuilder.parse(inFile);
                DOMResult domResult = new DOMResult();
                DOMSource domSource = new DOMSource(doc); // <--- error
on this line
                transformer.transform(domSource, domResult);
                domSource.setSystemId(inFile.toURL().toString());
                Serializer serializer = SerializerFactory.getSerializer
                   
(OutputProperties.getDefaultMethodProperties("html"));
                serializer.setOutputStream(new
FileOutputStream(outFile));
               
serializer.asDOMSerializer().serialize(domResult.getNode());
		... end of the try block, etc...

The error reports the line "DOMSource domSrouce = ..." to be the source
of error. Can somebody tell me what can possibly be wrong?

Will