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,java.lang.reflect.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,java.lang.reflect.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)
           
 
Method Summary
 T create(javax.enterprise.context.spi.CreationalContext<T> creationalContext)
           
 void destroy(T instance, javax.enterprise.context.spi.CreationalContext<T> creationalContext)
           
protected  java.lang.String getDefaultName()
          Gets the default name of the bean
 WeldParameter<?,? super X> getDisposesParameter()
           
 java.lang.String getName()
          Gets the name of the bean
 java.lang.Class<? extends java.lang.annotation.Annotation> getScope()
          Gets the scope type of the bean
 AbstractBean<?,?> getSpecializedBean()
           
 java.util.Set<java.lang.Class<? extends java.lang.annotation.Annotation>> getStereotypes()
           
 java.lang.Class<T> getType()
          Gets the type of the bean
 java.util.Set<java.lang.reflect.Type> getTypes()
          Gets the API types of the bean
 WeldMethod<T,? super X> getWeldAnnotated()
          Returns the annotated item the bean represents
 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(java.lang.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)
           
 
Methods inherited from class org.jboss.weld.bean.AbstractReceiverBean
getDeclaringBean, getReceiver, initAlternative
 
Methods inherited from class org.jboss.weld.bean.AbstractBean
addInjectionPoint, addInjectionPoints, checkDelegateInjectionPoints, getDelegateInjectionPoints, getMergedStereotypes, getNewInjectionPoints, getQualifiers, getTypedTypes, getWeldInjectionPoints, initDefaultQualifiers, initName, initScopeFromStereotype, initStereotypes, isAlternative, isDependent, isInitialized, isNormalScoped, isPrimitive, isSpecializing, postSpecialize, preSpecialize, specialize
 
Methods inherited from class org.jboss.weld.bean.RIBean
checkType, equals, getBeanClass, getBeanManager, getId, getInjectionPoints, hashCode, initializeAfterBeanDiscovery, isProxyRequired, toString
 
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)
Method Detail

of

public static <X,T> DisposalMethod<X,T> of(BeanManagerImpl manager,
                                           WeldMethod<T,? super X> method,
                                           AbstractClassBean<X> declaringBean)

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,java.lang.reflect.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,java.lang.reflect.Method>
Returns:
The annotated item

initQualifiers

protected void initQualifiers()
Overrides:
initQualifiers in class AbstractBean<T,java.lang.reflect.Method>

initTypes

protected void initTypes()
Initializes the API types

Overrides:
initTypes in class AbstractBean<T,java.lang.reflect.Method>

getName

public java.lang.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,java.lang.reflect.Method>
Returns:
The name
See Also:
org.jboss.weld.bean.BaseBean#getName()

getScope

public java.lang.Class<? extends java.lang.annotation.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,java.lang.reflect.Method>
Returns:
The scope type
See Also:
org.jboss.weld.bean.BaseBean#getScope()

getTypes

public java.util.Set<java.lang.reflect.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,java.lang.reflect.Method>
Returns:
The set of API types
See Also:
org.jboss.weld.bean.BaseBean#getTypeClosure()

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,java.lang.reflect.Method>
Returns:
True if nullable, false otherwise
See Also:
org.jboss.weld.bean.BaseBean#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()
Overrides:
isProxyable in class AbstractBean<T,java.lang.reflect.Method>

create

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

invokeDisposeMethod

public void invokeDisposeMethod(java.lang.Object instance)

getType

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

Overrides:
getType in class AbstractBean<T,java.lang.reflect.Method>
Returns:
The type

getDefaultName

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

Specified by:
getDefaultName in class AbstractBean<T,java.lang.reflect.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,java.lang.reflect.Method>

initScope

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

getStereotypes

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


Copyright © 2008-2010 Seam Framework. All Rights Reserved.