javax.enterprise.inject.spi
Interface BeforeBeanDiscovery


public interface BeforeBeanDiscovery

This event type is thrown by the container before the bean discovery process begins. If any observer method of the BeforeBeanDiscovery event throws an exception, the exception is treated as a definition error by the container.

Author:
Pete Muir, David Allen

Method Summary
 void addAnnotatedType(AnnotatedType<?> type)
          Adds a given AnnotatedType to the set of types which will be scanned during bean discovery.
 void addInterceptorBinding(Class<? extends Annotation> bindingType, Annotation... bindingTypeDef)
           Declares an annotation type as an interceptor binding type, and specifies its meta-annotations.
 void addQualifier(Class<? extends Annotation> qualifier)
           Declares an annotation type as a Qualifier qualifier type.
 void addScope(Class<? extends Annotation> scopeType, boolean normal, boolean passivating)
           Declares an annotation type as a scope type.
 void addStereotype(Class<? extends Annotation> stereotype, Annotation... stereotypeDef)
           Declares an annotation type as a stereotype, and specifies its meta-annotations.
 

Method Detail

addQualifier

void addQualifier(Class<? extends Annotation> qualifier)

Declares an annotation type as a Qualifier qualifier type.

This is only required if you wish to make an annotation a qualifier without adding Qualifier to it.

Parameters:
qualifier - The annotation to treat as a qualifier

addScope

void addScope(Class<? extends Annotation> scopeType,
              boolean normal,
              boolean passivating)

Declares an annotation type as a scope type.

This is only required if you wish to make an annotation a scope type without adding the NormalScope or Scope annotations to it. You can also use this method to override an existing normal scope definition.

Parameters:
scopeType - The annotation type to treat as a scope type
normal - Indicates if the scope is normal
passivating - Indicates if the scope is passivation capable
See Also:
AfterBeanDiscovery.addContext(javax.enterprise.context.spi.Context)

addStereotype

void addStereotype(Class<? extends Annotation> stereotype,
                   Annotation... stereotypeDef)

Declares an annotation type as a stereotype, and specifies its meta-annotations.

This is only required if you wish to make an annotation a stereotype without adding Stereotype to it. You can also use this method to override an existing stereotype definition.

Parameters:
stereotype - The annotation type to treat as a stereotype
stereotypeDef - An optional list of annotations defining the stereotype

addInterceptorBinding

void addInterceptorBinding(Class<? extends Annotation> bindingType,
                           Annotation... bindingTypeDef)

Declares an annotation type as an interceptor binding type, and specifies its meta-annotations.

This is only required if you wish to make an annotation an interceptor binding type without adding InterceptorBinding to it.

Parameters:
bindingType - The annotation type to treat as an interceptor binding type
bindingTypeDef - An optional list of annotations defining the interceptor

addAnnotatedType

void addAnnotatedType(AnnotatedType<?> type)
Adds a given AnnotatedType to the set of types which will be scanned during bean discovery.

Parameters:
type - The AnnotatedType to add for later scanning


Copyright © 2008-2012 JBoss by Red Hat, Inc.. All Rights Reserved.