Configures component scanning directives for use with @
Provides support parallel with Spring XML's
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 declares this annotation.
Note that the
<context:component-scan> element has an
annotation-config attribute; however, this annotation does not. This is because
in almost all cases when using
@ComponentScan, default annotation config
processing (e.g. processing
@Autowired and friends) is assumed. Furthermore,
AnnotationConfigApplicationContext, annotation config processors are
always registered, meaning that any attempt to disable them at the
@ComponentScan level would be ignored.
@Configuration's Javadoc for usage examples.