Annotation
Use
Description
@Autowired Constructor,Field,Method Declares a constructor, field, setter method,
or configuration method to be autowired by
type. Items annotated with @Autowired do
not have to be public.
@Configurable Type Used with
declare types whose properties should be
injected, even if they are not instantiated by
Spring. Typically used to inject the properties
of domain objects.
@Order Type,Method,Field Defines ordering, as an alternative to
implementing the org.springframework.core.
Ordered interface.
@Qualifier Field,Parameter, Type,Annotation Type Guides autowiring to be performed
by means other than by type.
@Required Method (setters) Specifies that a particular property must be
injected or else the configuration will fail.
@Scope Type Specifies the scope of a bean, either
singleton, prototype, request, session, or
some custom scope.
No comments:
Post a Comment