bean注解和component @configuration和@component之间的区别是什么?

@configuration和@component之间的区别是什么?@configuration和@component之间的区别是:@Component注解的范围最广,所有类都可以注解,但是@Conf

@configuration和@component之间的区别是什么?

@configuration和@component之间的区别是:@Component注解的范围最广,所有类都可以注解,但是@Configuration注解一般注解在这样的类上:这个类里面有@Value注解的成员变量和@Bean注解的方法,就是一个配置类。