Package org.jboss.weld.bean.builtin.ee
Class EEResourceProducerField<X,T>
- java.lang.Object
-
- org.jboss.weld.util.bean.ForwardingBeanAttributes<T>
-
- org.jboss.weld.bean.CommonBean<T>
-
- org.jboss.weld.bean.RIBean<T>
-
- org.jboss.weld.bean.AbstractBean<T,S>
-
- org.jboss.weld.bean.AbstractProducerBean<X,T,Field>
-
- org.jboss.weld.bean.ProducerField<X,T>
-
- org.jboss.weld.bean.builtin.ee.EEResourceProducerField<X,T>
-
- All Implemented Interfaces:
Contextual<T>
,Bean<T>
,BeanAttributes<T>
,PassivationCapable
,WeldBean<T>
- Direct Known Subclasses:
StaticEEResourceProducerField
public class EEResourceProducerField<X,T> extends ProducerField<X,T>
- Author:
- pmuir
-
-
Field Summary
-
Fields inherited from class org.jboss.weld.bean.AbstractBean
type
-
Fields inherited from class org.jboss.weld.bean.RIBean
beanManager
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
EEResourceProducerField(BeanAttributes<T> attributes, EnhancedAnnotatedField<T,? super X> field, AbstractClassBean<X> declaringBean, DisposalMethod<X,?> disposalMethod, BeanManagerImpl manager, org.jboss.weld.bootstrap.api.ServiceRegistry services)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
checkEEResource()
T
create(CreationalContext<T> creationalContext)
Creates an instance of the beanvoid
internalInitialize(BeanDeployerEnvironment environment)
Initializes the bean and its metadatastatic boolean
isEEResourceProducerField(BeanManagerImpl beanManager, AnnotatedField<?> field)
boolean
isPassivationCapableBean()
static <X,T>
EEResourceProducerField<X,T>of(BeanAttributes<T> attributes, EnhancedAnnotatedField<T,? super X> field, AbstractClassBean<X> declaringBean, DisposalMethod<X,?> disposalMethod, BeanManagerImpl manager, org.jboss.weld.bootstrap.api.ServiceRegistry services)
Creates an EE resource producer fieldString
toString()
-
Methods inherited from class org.jboss.weld.bean.ProducerField
cleanupAfterBoot, getAnnotated, getEnhancedAnnotated, getSpecializedBeans, isProxyable, isSpecializing
-
Methods inherited from class org.jboss.weld.bean.AbstractProducerBean
checkReturnValue, checkType, destroy, getBeanClass, getDeclaringBean, getInjectionPoints, initType, isPassivationCapableDependency, isTypeSerializable
-
Methods inherited from class org.jboss.weld.bean.AbstractBean
checkSpecialization, getProducer, getType, initializeAfterBeanDiscovery, isDependent, isIgnoreFinalMethods, isProxyRequired, postSpecialize, preInitialize, preSpecialize, setIgnoreFinalMethods, setProducer, specialize
-
Methods inherited from class org.jboss.weld.bean.RIBean
getBeanManager, getContextualInstanceStrategy, getQualifierInstances, initialize, isNormalScoped, setAttributes
-
Methods inherited from class org.jboss.weld.bean.CommonBean
attributes, equals, getId, getIdentifier, hashCode, isNullable, 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 jakarta.enterprise.inject.spi.PassivationCapable
getId
-
Methods inherited from interface org.jboss.weld.bean.WeldBean
getPriority
-
-
-
-
Constructor Detail
-
EEResourceProducerField
protected EEResourceProducerField(BeanAttributes<T> attributes, EnhancedAnnotatedField<T,? super X> field, AbstractClassBean<X> declaringBean, DisposalMethod<X,?> disposalMethod, BeanManagerImpl manager, org.jboss.weld.bootstrap.api.ServiceRegistry services)
-
-
Method Detail
-
of
public static <X,T> EEResourceProducerField<X,T> of(BeanAttributes<T> attributes, EnhancedAnnotatedField<T,? super X> field, AbstractClassBean<X> declaringBean, DisposalMethod<X,?> disposalMethod, BeanManagerImpl manager, org.jboss.weld.bootstrap.api.ServiceRegistry services)
Creates an EE resource producer field- Parameters:
field
- The underlying method abstractiondeclaringBean
- The declaring bean abstractionmanager
- the current manager- Returns:
- A producer field
-
isEEResourceProducerField
public static boolean isEEResourceProducerField(BeanManagerImpl beanManager, AnnotatedField<?> field)
- Parameters:
beanManager
-field
-- Returns:
true
if the given field is annotated with an EE resource annotation,false
otherwise
-
internalInitialize
public void internalInitialize(BeanDeployerEnvironment environment)
Description copied from class:AbstractProducerBean
Initializes the bean and its metadata- Overrides:
internalInitialize
in classAbstractProducerBean<X,T,Field>
-
checkEEResource
protected void checkEEResource()
-
create
public T create(CreationalContext<T> creationalContext)
Description copied from class:AbstractProducerBean
Creates an instance of the bean- Specified by:
create
in interfaceContextual<X>
- Overrides:
create
in classAbstractProducerBean<X,T,Field>
- Parameters:
creationalContext
- the context in which this instance is being created- Returns:
- the contextual instance
-
isPassivationCapableBean
public boolean isPassivationCapableBean()
- Overrides:
isPassivationCapableBean
in classAbstractProducerBean<X,T,Field>
-
toString
public String toString()
- Overrides:
toString
in classProducerField<X,T>
-
-