Package org.jboss.weld.bean
Class RIBean<T>
- java.lang.Object
-
- org.jboss.weld.util.bean.ForwardingBeanAttributes<T>
-
- org.jboss.weld.bean.CommonBean<T>
-
- org.jboss.weld.bean.RIBean<T>
-
- All Implemented Interfaces:
jakarta.enterprise.context.spi.Contextual<T>
,jakarta.enterprise.inject.spi.Bean<T>
,jakarta.enterprise.inject.spi.BeanAttributes<T>
,jakarta.enterprise.inject.spi.PassivationCapable
,WeldBean<T>
- Direct Known Subclasses:
AbstractBean
,AbstractBuiltInBean
public abstract class RIBean<T> extends CommonBean<T> implements jakarta.enterprise.inject.spi.PassivationCapable
Abstract base class with functions specific to RI built-in beans- Author:
- Pete Muir
-
-
Field Summary
Fields Modifier and Type Field Description protected BeanManagerImpl
beanManager
-
Constructor Summary
Constructors Modifier Constructor Description protected
RIBean(jakarta.enterprise.inject.spi.BeanAttributes<T> attributes, org.jboss.weld.serialization.spi.BeanIdentifier identifier, BeanManagerImpl beanManager)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
cleanupAfterBoot()
This method is called after the container is started allowing the bean to release any resources that are only required at boot timevoid
destroy(T instance, jakarta.enterprise.context.spi.CreationalContext<T> creationalContext)
Class<?>
getBeanClass()
BeanManagerImpl
getBeanManager()
ContextualInstanceStrategy<T>
getContextualInstanceStrategy()
Set<QualifierInstance>
getQualifierInstances()
abstract Class<T>
getType()
void
initialize(BeanDeployerEnvironment environment)
Initializes the bean and its metadata.abstract void
initializeAfterBeanDiscovery()
In particular cases, the deployer must perform some initialization operations only after all beans have been deployed (e.g.protected abstract void
internalInitialize(BeanDeployerEnvironment environment)
boolean
isDependent()
boolean
isNormalScoped()
abstract boolean
isPassivationCapableBean()
abstract boolean
isPassivationCapableDependency()
abstract boolean
isProxyable()
abstract boolean
isProxyRequired()
abstract void
preInitialize()
void
setAttributes(jakarta.enterprise.inject.spi.BeanAttributes<T> attributes)
-
Methods inherited from class org.jboss.weld.bean.CommonBean
attributes, equals, getId, getIdentifier, hashCode, isNullable, toString, unwrap
-
Methods inherited from class org.jboss.weld.util.bean.ForwardingBeanAttributes
getName, getQualifiers, getScope, getStereotypes, getTypes, isAlternative
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jakarta.enterprise.inject.spi.BeanAttributes
getName, getQualifiers, getScope, getStereotypes, getTypes, isAlternative
-
Methods inherited from interface org.jboss.weld.bean.WeldBean
getPriority
-
-
-
-
Field Detail
-
beanManager
protected final BeanManagerImpl beanManager
-
-
Constructor Detail
-
RIBean
protected RIBean(jakarta.enterprise.inject.spi.BeanAttributes<T> attributes, org.jboss.weld.serialization.spi.BeanIdentifier identifier, BeanManagerImpl beanManager)
-
-
Method Detail
-
getBeanManager
public BeanManagerImpl getBeanManager()
-
getBeanClass
public Class<?> getBeanClass()
- Specified by:
getBeanClass
in interfacejakarta.enterprise.inject.spi.Bean<T>
-
preInitialize
public abstract void preInitialize()
-
initialize
public final void initialize(BeanDeployerEnvironment environment)
Initializes the bean and its metadata. The method is synchronized and guarded by the RIBean object so that the initialization only occurs once.
-
internalInitialize
protected abstract void internalInitialize(BeanDeployerEnvironment environment)
-
cleanupAfterBoot
public abstract void cleanupAfterBoot()
This method is called after the container is started allowing the bean to release any resources that are only required at boot time
-
initializeAfterBeanDiscovery
public abstract void initializeAfterBeanDiscovery()
In particular cases, the deployer must perform some initialization operations only after all beans have been deployed (e.g. for initializing decorators taking into account the possibility of having custom decorators which are deployed through portable extensions)- Parameters:
environment
-
-
isDependent
public boolean isDependent()
-
isNormalScoped
public boolean isNormalScoped()
-
isProxyable
public abstract boolean isProxyable()
-
isPassivationCapableBean
public abstract boolean isPassivationCapableBean()
-
isPassivationCapableDependency
public abstract boolean isPassivationCapableDependency()
-
isProxyRequired
public abstract boolean isProxyRequired()
-
getQualifierInstances
public Set<QualifierInstance> getQualifierInstances()
-
getContextualInstanceStrategy
public ContextualInstanceStrategy<T> getContextualInstanceStrategy()
-
setAttributes
public void setAttributes(jakarta.enterprise.inject.spi.BeanAttributes<T> attributes)
- Overrides:
setAttributes
in classCommonBean<T>
-
-