| org.springframework.context.annotation.ComponentScan |
Configures component scanning directives for use with @Configuration
classes. Provides support parallel with Spring XML's <context:component-scan>
element.
One of #basePackageClasses(), #basePackages() or its alias #value() must be specified.
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, when using
AnnotationConfigApplicationContext, annotation config processors are always
registered, meaning that any attempt to disable them at the @ComponentScan level
would be ignored.
| Nested Classes | |||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ComponentScan.Filter | Declares the type filter to be used as an ComponentScan#includeFilters() include filter or ComponentScan#includeFilters() exclude filter. | ||||||||||||||||||
|
[Expand]
Inherited Methods | |||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
From interface
java.lang.annotation.Annotation
| |||||||||||||||||||
