当处理如下代码:
1
2
|
Javassist Enhancement failed: com.entities.Department
java.lang.ClassCastException: com.entities.Department_$$_javassist_1 cannot be cast to javassist.util.proxy.Proxy
|
1
2
3
|
<many-to-one name=
"department"
class
=
"com.entities.Department"
>
<column name=
"DEPARTMENT_ID"
/>
</many-to-one>
|
当输出数据到页面时候出现如下错误:
1
2
|
Javassist Enhancement failed: com.entities.Department
java.lang.ClassCastException: com.entities.Department_$$_javassist_1 cannot be cast to javassist.util.proxy.Proxy
|
原因是有两个javassis的jar包,一个是hibernate的,一个是struts2的...,把低版本的删掉即可!