Either basePackageClasses or basePackages (or its alias value) may be specified to define specific packages to scan. If specific packages are not defined, scanning will occur from the package of the class that
* String-based package names.*/@AliasFor("value") String[] basePackages()default{};/*** 指定具体的扫描的类 * Type-safe alternative to {@link#basePackages} for specifying the packages * to scan for annotated components. The package of each class specified will be scanned. * Consider creating...
spring容器启动的核心refresh方法我相信大家都不陌生,其中invokeBeanFactoryPostProcessors方法是处理beanFactory的一个非常重要的方法,@Component @Bean等等都是在该方法里实现解析的。 1@Configuration2@ComponentScan("org.springframework.context.annotation")3publicclassMyComponentScan {4@ComponentScan("org.springframewo...