Package org.apache.webbeans.spi
Enum BeanArchiveService.BeanDiscoveryMode
- java.lang.Object
-
- java.lang.Enum<BeanArchiveService.BeanDiscoveryMode>
-
- org.apache.webbeans.spi.BeanArchiveService.BeanDiscoveryMode
-
- All Implemented Interfaces:
Serializable
,Comparable<BeanArchiveService.BeanDiscoveryMode>
- Enclosing interface:
- BeanArchiveService
public static enum BeanArchiveService.BeanDiscoveryMode extends Enum<BeanArchiveService.BeanDiscoveryMode>
Defines how CDI beans got discovered for each JAR or ClassPath entry (aka BDA).
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ALL
Pick up all classes as CDI beans.ANNOTATED
Only classes with a 'bean defining annotation' will get picked up as CDI beans.NONE
Ignore all classes in this BDA when it comes to beans scanning.TRIM
Pick up all classes (like withALL
and fire the ProcessAnnotatedType event for them.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static BeanArchiveService.BeanDiscoveryMode
getByOrdinal(int ordinal)
int
getOrdinal()
static BeanArchiveService.BeanDiscoveryMode
max(BeanArchiveService.BeanDiscoveryMode bdmA, BeanArchiveService.BeanDiscoveryMode bdmB)
static BeanArchiveService.BeanDiscoveryMode
valueOf(String name)
Returns the enum constant of this type with the specified name.static BeanArchiveService.BeanDiscoveryMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
TRIM
public static final BeanArchiveService.BeanDiscoveryMode TRIM
Pick up all classes (like withALL
and fire the ProcessAnnotatedType event for them. But only pick up the scanned class as CDI bean:- if they have an explicit CDI scope annotation, or
- if they are an Interceptor or Decorator
- if they are a JavaEE managed bean
ALL
mode beans without any scope will not get picked up as @Dependent scoped beans!
-
ALL
public static final BeanArchiveService.BeanDiscoveryMode ALL
Pick up all classes as CDI beans. Classes with no 'bean defining annotations' will get picked up as @Dependent scoped beans. This is basically the backward compatible mode to CDI-1.0.
-
ANNOTATED
public static final BeanArchiveService.BeanDiscoveryMode ANNOTATED
Only classes with a 'bean defining annotation' will get picked up as CDI beans. A 'bean defining annotation' is any CDI or atinject Scope annotation as well as Stereotypes (the later only since CDI-1.2)
-
NONE
public static final BeanArchiveService.BeanDiscoveryMode NONE
Ignore all classes in this BDA when it comes to beans scanning.
-
-
Method Detail
-
values
public static BeanArchiveService.BeanDiscoveryMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (BeanArchiveService.BeanDiscoveryMode c : BeanArchiveService.BeanDiscoveryMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static BeanArchiveService.BeanDiscoveryMode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getOrdinal
public int getOrdinal()
-
getByOrdinal
public static BeanArchiveService.BeanDiscoveryMode getByOrdinal(int ordinal)
-
max
public static BeanArchiveService.BeanDiscoveryMode max(BeanArchiveService.BeanDiscoveryMode bdmA, BeanArchiveService.BeanDiscoveryMode bdmB)
-
-