You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by "Peter B. West" <li...@pbw.id.au> on 2005/01/03 16:04:33 UTC
Problems running example DOM3 parser creation
Following the example, on the Programming with DOM page, for creating a
DOM3 LS parser, I get a
ClassCastException: org.apache.xerces.dom.DOMImplementationSourceImpl
at org.w3c.dom.bootstrap.DOMImplementationRegistry.newInstance(
DOMImplementationRegistry.java:144)
i.e. at
DOMImplementationSource source =
(DOMImplementationSource) sourceClass.newInstance();
The code, taken from the example, is
DOMImplementationRegistry registry = null;
System.setProperty(DOMImplementationRegistry.PROPERTY,
"org.apache.xerces.dom.DOMImplementationSourceImpl");
try {
registry = DOMImplementationRegistry.newInstance();
} catch (Exception e) {
throw new RuntimeException(e);
}
Any idea what I'm doing wrong?
Peter
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org