错误原因:
this.getClass().getGenericSuperclass()返回将是class,该this就是当前类的对象,所以一个被泛型化的类是不能被实例化的,只有不被实例化,返回的类型才是ParameterizedType
修改方法一:
修改方法二:
<bean id="departmentDao" class="dao.impl.DepartmentDaoImpl">
<property name="hibernateTemplate">
<ref bean="hibernateTemplate"/>
</property>
</bean>