Java_异常_02_java.lang.NoClassDefFoundError: org/apache/log4j/Level

总结:解析Json时,除了要导入json-lib-2.2-jdk15.jar外,还要导入:

commons-beanutils.jar,

commons-httpclient.jar,

commons-lang.jar,

ezmorph.jar,

morph-1.0.1.jar 

 

1.异常1信息:

Failed to instantiate SLF4J LoggerFactory Reported exception: java.lang.NoClassDefFoundError: org/apache/log4j/Level

解读:找不到log4j的jar包

添加了log4j的jar包之后,又出现异常2.

 

2.异常2信息:

java.lang.NoClassDefFoundError: net/sf/ezmorph/Morpher

解读:找不到 ezmorph.jar,morph-1.0.1.jar。添加之

 

posted @ 2017-08-08 21:45  shirayner  阅读(2599)  评论(0编辑  收藏  举报