我想将 Jackson2 与SpringRoboSpice
. 我的 libs 文件夹包含以下 jars 。
- commons-io-1.3.2.jar
- commons-lang3-3.2.1.jar
- jackson-annotations-2.2.3.jar
- 杰克逊核心2.2.3.jar
- jackson-databind-2.2.3.jar
- robospice-1.4.11.jar
- robospice-cache-1.4.11.jar
- robospice-spring-android-1.4.11.jar
- spring-android-core-1.0.1.RELEASE.jar
- spring-android-rest-template-1.0.1.RELEASE.jar
如此处所写将切换到如果找到jackson2 jars。SpringAndroidSpiceService
jackson2
应用程序崩溃并出现此异常:
java.lang.NoClassDefFoundError: org.codehaus.jackson.map.ObjectMapper
at org.springframework.http.converter.json.MappingJacksonHttpMessageConverter.<init>(MappingJacksonHttpMessageConverter.java:54)
at com.octo.android.robospice.JacksonSpringAndroidSpiceService.createRestTemplate(JacksonSpringAndroidSpiceService.java:33)
at com.octo.android.robospice.SpringAndroidSpiceService.onCreate(SpringAndroidSpiceService.java:26)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:2572)
at android.app.ActivityThread.access$1800(ActivityThread.java:135)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1278)
我错过了什么?