org.jboss.weld.bean
Class DisposalMethod<X,T>

java.lang.Object
  extended by org.jboss.weld.bean.RIBean<T>
      extended by org.jboss.weld.bean.AbstractBean<T,S>
          extended by org.jboss.weld.bean.AbstractReceiverBean<X,T,Method>
              extended by org.jboss.weld.bean.DisposalMethod<X,T>
All Implemented Interfaces:
javax.enterprise.context.spi.Contextual<T>, javax.enterprise.inject.spi.Bean<T>, javax.enterprise.inject.spi.PassivationCapable

public class DisposalMethod<X,T>
extends AbstractReceiverBean<X,T,Method>


Field Summary
protected  MethodInjectionPoint<T,? super X> disposalMethodInjectionPoint
           
 
Fields inherited from class org.jboss.weld.bean.AbstractBean
alternative, beanManager, name, qualifiers, scope, type, types
 
Fields inherited from class org.jboss.weld.bean.RIBean
BEAN_ID_PREFIX, BEAN_ID_SEPARATOR
 
Constructor Summary
protected DisposalMethod(BeanManagerImpl beanManager, WeldMethod<T,? super X> disposalMethod, AbstractClassBean<X> declaringBean, org.jboss.weld.bootstrap.api.ServiceRegistry services)
           
 
Method Summary
protected  void checkType()
           
 T create(javax.enterprise.context.spi.CreationalContext<T> creationalContext)
           
 void destroy(T instance, javax.enterprise.context.spi.CreationalContext<T> creationalContext)
           
protected  String getDefaultName()
          Gets the default name of the bean
 WeldParameter<?,? super X> getDisposesParameter()
           
 String getName()
          Gets the name of the bean
 Class<? extends Annotation> getScope()
          Gets the scope type of the bean
 AbstractBean<?,?> getSpecializedBean()
           
 Set<Class<? extends Annotation>> getStereotypes()
           
 Class<T> getType()
          Gets the type of the bean
 Set<Type> getTypes()
          Gets the API types of the bean
 WeldMethod<T,? super X> getWeldAnnotated()
          Returns the annotated item the bean represents
 boolean hasDefaultProducer()
          Returns true if the bean uses the default Producer ( or InjectionTarget).
 void initialize(BeanDeployerEnvironment environment)
          Initializes the bean and its metadata
protected  void initQualifiers()
           
protected  void initScope()
           
protected  void initType()
           
protected  void initTypes()
          Initializes the API types
 void invokeDisposeMethod(Object instance)
           
 boolean isNullable()
          Indicates if bean is nullable
 boolean isPassivationCapableBean()
           
 boolean isPassivationCapableDependency()
           
 boolean isProxyable()
           
static
<X,T> DisposalMethod<X,T>
of(BeanManagerImpl manager, WeldMethod<T,? super X> method, AbstractClassBean<X> declaringBean, org.jboss.weld.bootstrap.api.ServiceRegistry services)
           
 String toString()
           
 
Methods inherited from class org.jboss.weld.bean.AbstractReceiverBean
getDeclaringBean, getReceiver
 
Methods inherited from class org.jboss.weld.bean.AbstractBean
addInjectionPoint, addInjectionPoints, checkDelegateInjectionPoints, cleanupAfterBoot, getDelegateInjectionPoints, getMergedStereotypes, getNewInjectionPoints, getQualifiers, getServices, getTypedTypes, getWeldInjectionPoints, initAlternative, initDefaultQualifiers, initializeAfterBeanDiscovery, initName, initScopeFromStereotype, initStereotypes, isAlternative, isDependent, isInitialized, isNormalScoped, isPrimitive, isProxyRequired, isSpecializing, postSpecialize, preSpecialize, specialize
 
Methods inherited from class org.jboss.weld.bean.RIBean
equals, getBeanClass, getBeanManager, getId, getInjectionPoints, getQualifierInstances, hashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

disposalMethodInjectionPoint

protected MethodInjectionPoint<T,? super X> disposalMethodInjectionPoint
Constructor Detail

DisposalMethod

protected DisposalMethod(BeanManagerImpl beanManager,
                         WeldMethod<T,? super X> disposalMethod,
                         AbstractClassBean<X> declaringBean,
                         org.jboss.weld.bootstrap.api.ServiceRegistry services)
Method Detail

of

public static <X,T> DisposalMethod<X,T> of(BeanManagerImpl manager,
                                           WeldMethod<T,? super X> method,
                                           AbstractClassBean<X> declaringBean,
                                           org.jboss.weld.bootstrap.api.ServiceRegistry services)

getDisposesParameter

public WeldParameter<?,? super X> getDisposesParameter()

initialize

public void initialize(BeanDeployerEnvironment environment)
Description copied from class: AbstractBean
Initializes the bean and its metadata

Overrides:
initialize in class AbstractReceiverBean<X,T,Method>

initType

protected void initType()

getWeldAnnotated

public WeldMethod<T,? super X> getWeldAnnotated()
Description copied from class: AbstractBean
Returns the annotated item the bean represents

Specified by:
getWeldAnnotated in class AbstractReceiverBean<X,T,Method>
Returns:
The annotated item

initQualifiers

protected void initQualifiers()
Overrides:
initQualifiers in class AbstractBean<T,Method>

initTypes

protected void initTypes()
Initializes the API types

Overrides:
initTypes in class AbstractBean<T,Method>

getName

public String getName()
Description copied from class: AbstractBean
Gets the name of the bean

Specified by:
getName in interface javax.enterprise.inject.spi.Bean<T>
Overrides:
getName in class AbstractBean<T,Method>
Returns:
The name
See Also:
Bean.getName()

getScope

public Class<? extends Annotation> getScope()
Description copied from class: AbstractBean
Gets the scope type of the bean

Specified by:
getScope in interface javax.enterprise.inject.spi.Bean<T>
Overrides:
getScope in class AbstractBean<T,Method>
Returns:
The scope type
See Also:
Bean.getScope()

getTypes

public Set<Type> getTypes()
Description copied from class: AbstractBean
Gets the API types of the bean

Specified by:
getTypes in interface javax.enterprise.inject.spi.Bean<T>
Overrides:
getTypes in class AbstractBean<T,Method>
Returns:
The set of API types
See Also:
Bean.getTypes()

isNullable

public boolean isNullable()
Description copied from class: AbstractBean
Indicates if bean is nullable

Specified by:
isNullable in interface javax.enterprise.inject.spi.Bean<T>
Overrides:
isNullable in class AbstractBean<T,Method>
Returns:
True if nullable, false otherwise
See Also:
Bean.isNullable()

isPassivationCapableBean

public boolean isPassivationCapableBean()
Specified by:
isPassivationCapableBean in class RIBean<T>

isPassivationCapableDependency

public boolean isPassivationCapableDependency()
Specified by:
isPassivationCapableDependency in class RIBean<T>

isProxyable

public boolean isProxyable()
Specified by:
isProxyable in class RIBean<T>

create

public T create(javax.enterprise.context.spi.CreationalContext<T> creationalContext)

invokeDisposeMethod

public void invokeDisposeMethod(Object instance)

checkType

protected void checkType()
Specified by:
checkType in class AbstractBean<T,Method>

getType

public Class<T> getType()
Description copied from class: AbstractBean
Gets the type of the bean

Overrides:
getType in class AbstractBean<T,Method>
Returns:
The type

getDefaultName

protected String getDefaultName()
Description copied from class: AbstractBean
Gets the default name of the bean

Specified by:
getDefaultName in class AbstractBean<T,Method>
Returns:
The default name

destroy

public void destroy(T instance,
                    javax.enterprise.context.spi.CreationalContext<T> creationalContext)

getSpecializedBean

public AbstractBean<?,?> getSpecializedBean()
Specified by:
getSpecializedBean in class AbstractBean<T,Method>

initScope

protected void initScope()
Specified by:
initScope in class AbstractBean<T,Method>

getStereotypes

public Set<Class<? extends Annotation>> getStereotypes()
Specified by:
getStereotypes in interface javax.enterprise.inject.spi.Bean<T>
Overrides:
getStereotypes in class AbstractBean<T,Method>

toString

public String toString()
Overrides:
toString in class RIBean<T>

hasDefaultProducer

public boolean hasDefaultProducer()
Description copied from class: AbstractBean
Returns true if the bean uses the default Producer ( or InjectionTarget). The method returns false if the producer of the bean was replaced by an extension.

Specified by:
hasDefaultProducer in class AbstractBean<T,Method>


Copyright © 2013 Seam Framework. All Rights Reserved.