-
Notifications
You must be signed in to change notification settings - Fork 11
Component Installation
LightGuard edited this page Jan 25, 2012
·
3 revisions
Seam 2 offers the @Install
annotation for controlling whether a given bean should be installed or not. The following concepts are supported and can be configured using the annotation:
- explicit prevention from installation
- installation dependencies
- bean selection based component ordering (precedence)
The CDI specification itself does not define a single replacement for all the functionality represented by the @Install annotation. Instead, the concepts are implemented separately.
Concept | Seam 2 | CDI / Seam 3 |
---|---|---|
explicit prevention from installation | @Install(false) |
|
installation dependencies | @Install(dependencies = “foo”) |
@Requires(“javax.persistence.EntityManager”)Note that class-level dependencies are supported only |
bean selection based component ordering (precedence) | @Install(precedence = MOCK) |
|