org.apache.webbeans.component
Class ResourceBean<X,T extends Annotation>
java.lang.Object
org.apache.webbeans.component.AbstractOwbBean<T>
org.apache.webbeans.component.AbstractProducerBean<T>
org.apache.webbeans.component.ProducerFieldBean<X>
org.apache.webbeans.component.ResourceBean<X,T>
- All Implemented Interfaces:
- javax.enterprise.context.spi.Contextual<X>, javax.enterprise.inject.spi.Bean<X>, IBeanHasParent<X>, OwbBean<X>
public class ResourceBean<X,T extends Annotation>
- extends ProducerFieldBean<X>
| Fields inherited from class org.apache.webbeans.component.AbstractOwbBean |
apiTypes, enabled, implQualifiers, implScopeType, injectionPoints, name, nullable, passivatingId, returnType, scopeClass, serializable, specializedBean, stereoTypeClasses, stereoTypes, webBeansType |
|
Method Summary |
protected X |
createInstance(javax.enterprise.context.spi.CreationalContext<X> creationalContext)
Creates the instance of the bean that has a specific implementation
type. |
X |
getActualInstance()
Called after deserialization to get a new instance for some type of resource bean instance that are
not serializable. |
boolean |
isPassivationCapable()
True if passivation capable false otherwise. |
| Methods inherited from class org.apache.webbeans.component.AbstractOwbBean |
addApiType, addInjectionPoint, addQualifier, addStereoType, create, createNewInstance, destroy, destroyCreatedInstance, equals, getBeanClass, getImplQualifiers, getImplScopeType, getInjectionPoint, getLogger, getManager, getName, getOwbStereotypes, getQualifiers, getReturnType, getScope, getStereotypes, getTypes, getWebBeansContext, getWebBeansType, hashCode, isAlternative, isDependent, isEnabled, isNullable, isSerializable, isSpecializedBean, setEnabled, setImplScopeType, setName, setNullable, setSerializable, setSpecializedBean |
ResourceBean
public ResourceBean(Class<X> returnType,
InjectionTargetBean<?> ownerBean,
ResourceReference<X,T> resourceReference)
createInstance
protected X createInstance(javax.enterprise.context.spi.CreationalContext<X> creationalContext)
- Description copied from class:
ProducerFieldBean
- Creates the instance of the bean that has a specific implementation
type. Each subclass must define its own create mechanism.
- Overrides:
createInstance in class ProducerFieldBean<X>
- Parameters:
creationalContext - the contextual instance shall be created in
- Returns:
- instance of the bean
getActualInstance
public X getActualInstance()
- Called after deserialization to get a new instance for some type of resource bean instance that are
not serializable.
- Returns:
- a new instance of this resource bean.
isPassivationCapable
public boolean isPassivationCapable()
- Description copied from interface:
OwbBean
- True if passivation capable false otherwise.
- Specified by:
isPassivationCapable in interface OwbBean<X>- Overrides:
isPassivationCapable in class ProducerFieldBean<X>
- Returns:
- true if this bean is passivation capable
Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.