有关注解的方面

id等于Class类名而且首字母小写
spring里面注解的方法要用到:<context:component-scan base-package=""></context:component-scan>
而java自带的注解用<context:annotation-config></context:annotation-config>就行

这个注解要写bean配置,个人理解是相当于在People类中获得了People的id和class,然后再获得了private Cat和private Dog的Bean配置,就是可以调用DO
og和Cat类中的方法

浙公网安备 33010602011771号