|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |
@Retention(value=RUNTIME) @Target(value={}) public static @interface ComponentScan.Filter
Declares the type filter to be used as an include filter or exclude filter.
Required Element Summary | |
---|---|
Class<?>[] |
value
The class or classes to use as the filter. |
Optional Element Summary | |
---|---|
FilterType |
type
The type of filter to use. |
Element Detail |
---|
public abstract Class<?>[] value
FilterType.ANNOTATION
, the class will be the annotation itself. In the
case of FilterType.ASSIGNABLE_TYPE
, the class will be the type that
detected components should be assignable to. And in the case of
FilterType.CUSTOM
, the class will be an implementation of
TypeFilter
.
When multiple classes are specified, OR logic is applied, e.g. "include
types annotated with @Foo
OR @Bar
".
Specifying zero classes is permitted but will have no effect on component scanning.
public abstract FilterType type
Note that the filter types available are limited to those that may
be expressed as a Class
in the value()
attribute. This is
in contrast to <context:component-scan/>
, which allows for
expression-based (i.e., string-based) filters such as AspectJ pointcuts.
These filter types are intentionally not supported here, and not available
in the FilterType
enum.
FilterType
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |