Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

using Xerces supplied with JAXP

843834Oct 15 2007 — edited Oct 17 2007
Why does this simple code throw javax.xml.parsers.FactoryConfigurationError with the message "Provider org.apache.xerces.jaxp.SAXParserFactoryImpl not found" in Java 5? I think the answer is that it should be looking for the renamed class com.sun.org.apache.xerces.jaxp.SAXParserFactoryImpl. But why doesn't it do that by default?

import javax.xml.parsers.*;

public class SAXValidate {

public static void main(String[] args) throws Exception {
SAXParserFactory factory = SAXParserFactory.newInstance();
SAXParser parser = factory.newSAXParser();
}
}
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 14 2007
Added on Oct 15 2007
10 comments
508 views