Using Xpath in Dom4j

后端 未结 5 976
悲哀的现实
悲哀的现实 2021-02-12 12:22

I get the following exception when trying to access any nodes of a parsed xml document on dom4j:

Exception in thread \"main\" java.lang.NoClassDefFoundError: or         


        
5条回答
  •  太阳男子
    2021-02-12 12:59

    So xpath works if I include jaxen-1.1-beta-6.jar in addition to the jdom4 jar. Note the jaxen-1.1.1.jar does not work. If you have a classdef error from jdom look at their dependencies and make sure you are using their approved jars, (which for the 1.6.1 version is now often an older release of the jar). Hope this helps anyone with a similar problem. Thanks again for everyone's help!

提交回复
热议问题