public class ProducerMethodBean<T> extends AbstractProducerBean<T>
AbstractOwbBean
.
It is defined as producer method component.
Modifier and Type | Field and Description |
---|---|
protected Method |
creatorMethod
Creator method of the parent component
|
protected Method |
disposalMethod
Disposal method
|
enabled, logger, passivatingId, specializedBean, webBeansContext, webBeansType
Constructor and Description |
---|
ProducerMethodBean(InjectionTargetBean<P> ownerComponent,
BeanAttributesImpl<T> beanAttributes,
Class<T> returnType,
MethodProducerFactory<P> producerFactory)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
T |
create(javax.enterprise.context.spi.CreationalContext<T> creationalContext) |
Method |
getCreatorMethod()
Gets the creator method.
|
Method |
getDisposalMethod() |
String |
getId()
get the unique Id of the bean.
|
boolean |
isPassivationCapable()
True if passivation capable false otherwise.
|
void |
setCreatorMethod(Method creatorMethod)
Sets the method.
|
void |
setDisposalMethod(Method disposalMethod)
Sets the disposal method.
|
checkNullInstance, checkScopeType, dispose, getOwnerBean, getProducer, getReturnType, isPassivationCapable
destroy, getBeanClass, getInjectionPoints, getLogger, getWebBeansContext, getWebBeansType, isAlternative, isDependent, isEnabled, isSpecializedBean, setEnabled, setSpecializedBean, toString
getName, getQualifiers, getScope, getStereotypes, getTypes, isNullable
protected Method creatorMethod
protected Method disposalMethod
public ProducerMethodBean(InjectionTargetBean<P> ownerComponent, BeanAttributesImpl<T> beanAttributes, Class<T> returnType, MethodProducerFactory<P> producerFactory)
ownerComponent
- parent beanreturnType
- producer method return typepublic Method getCreatorMethod()
public Method getDisposalMethod()
public void setCreatorMethod(Method creatorMethod)
creatorMethod
- producer methodpublic void setDisposalMethod(Method disposalMethod)
disposalMethod
- disposal method of this producer method componentpublic String getId()
AbstractOwbBean
public T create(javax.enterprise.context.spi.CreationalContext<T> creationalContext)
AbstractOwbBean
create
in interface javax.enterprise.context.spi.Contextual<T>
create
in class AbstractOwbBean<T>
public boolean isPassivationCapable()
OwbBean
isPassivationCapable
in interface OwbBean<T>
isPassivationCapable
in class AbstractOwbBean<T>
Copyright © 2008–2016 The Apache Software Foundation. All rights reserved.