隨筆-10  評論-23  文章-32  trackbacks-0

          when i do this:

          public static void main(String[] args) {
                  ApplicationContext ac = new ClassPathXmlApplicationContext("classpath:/applicationContext-ldap.xml");
                  System.out.println(ac.getBean("typeManager"));
              }

           

          i get this error:

          Exception in thread "main" java.lang.NoSuchMethodError: org.springframework.util.StringUtils.trimArrayElements([Ljava/lang/String;)[Ljava/lang/String;
              at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:120)
              at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:66)
              at cn.edu.zju.sgr.util.UpdateLdap.main(UpdateLdap.java:14)

           

          原因:

           

          解決方法:

          posted on 2010-01-21 10:22 liuyimx 閱讀(1968) 評論(2)  編輯  收藏

          評論:
          # re: org.springframework.util.StringUtils.trimArrayElements([Ljava/lang/String;) 2010-03-12 08:49 | da
          你的解決辦法是什么,請教了  回復  更多評論
            
          # re: org.springframework.util.StringUtils.trimArrayElements([Ljava/lang/String;) 2010-03-29 22:37 | liuyimx
          我也是在其他博客里看到,說原因是由于導入工程中的jar包有重復:同一個jar包不同版本,我調整了我的maven依賴配置,統一使用spring2.5的jar包后就沒有報錯了!詳細原因沒來得及深究。希望這個信息對你有用。  回復  更多評論
            

          只有注冊用戶登錄后才能發表評論。


          網站導航:
           
          主站蜘蛛池模板: 林西县| 东源县| 九江市| 奉化市| 乌苏市| 都江堰市| 准格尔旗| 曲阳县| 济南市| 重庆市| 三亚市| 宁南县| 洪江市| 双牌县| 江山市| 保定市| 临江市| 哈巴河县| 叶城县| 东莞市| 乌兰察布市| 宣汉县| 郎溪县| 苏尼特右旗| 九龙城区| 始兴县| 鸡泽县| 恩平市| 杂多县| 东平县| 射洪县| 育儿| 新昌县| 汝城县| 西宁市| 迁安市| 瑞金市| 竹溪县| 永平县| 潼关县| 宣汉县|