2013-08-25 64 views
0

在我的Java程序中,我創建了一個使用XOM讀取XML文件的類。我也在使用Spring。當行: ApplicationContext ctx = new ClassPathXmlApplicationContext("dataIO-beans.xml");執行,我得到它包括一個異常: javax.xml.parsers.ParserConfigurationException: Unable to validate using XSD: Your JAXP provider [[email protected]] does not support XML Schema. Are you running on Java 1.4 with Apache Crimson? Upgrade to Apache Xerces (or Java 1.5) for full XSD support. 如果我從Eclipse項目的構建路徑中刪除DTD-xercesImpl.jar,春季成功讀取XML文件中的豆,但現在我的XML閱讀課不起作用,因爲XOM需要那個jar文件。我該如何解決這個問題?Spring與XOM之間的衝突

回答