spring3.2以后的cglib的jar包问题

关于cglib的jar包官方的文档上有这么一段话

Note

For this dynamic subclassing to work, the class that the Spring container will subclass cannot be final, and the method to be overridden cannot be final either. Also, testing a class that has an abstract method requires you to subclass the class yourself and to supply a stub implementation of the abstract method. Finally, objects that have been the target of method injection cannot be serialized. As of Spring 3.2 it is no longer necessary to add CGLIB to your classpath, because CGLIB classes are repackaged under org.springframework and distributed within the spring-core JAR. This is done both for convenience as well as to avoid potential conflicts with other projects that use differing versions of CGLIB

 

意思是说,从spring3.2以后,spring框架本身不在需要CGLIB这个jar包了,因为cjlib.jar已经被spring项目的jar包集成进去。

为了防止项目中其他对cglib版本依赖不一样的冲突。

博客地址:http://www.cnblogs.com/shizhongtao/

posted @ 2013-11-20 09:36  bingyulei  阅读(1402)  评论(0编辑  收藏  举报