Package org.omnifaces.cdi.param
Class DynamicParamValueProducer
- java.lang.Object
-
- org.omnifaces.cdi.param.DynamicParamValueProducer
-
- All Implemented Interfaces:
Contextual<Object>,Bean<Object>,BeanAttributes<Object>,PassivationCapable
@Typed public class DynamicParamValueProducer extends Object implements Bean<Object>, PassivationCapable
Dynamic CDI producer used to work around CDI's restriction to create true generic producers.This dynamic producer calls through to the "real" producer for
@Paramannotated injection points.- Since:
- 2.0
- Author:
- Arjan Tijms
- See Also:
ParamExtension,ParamProducer
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDynamicParamValueProducer.DefaultParamAnnotationLiteralAnnotationLiteralforParam.
-
Constructor Summary
Constructors Constructor Description DynamicParamValueProducer(Type type)Construct dynamic param value producer for given type.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectcreate(CreationalContext<Object> creationalContext)voiddestroy(Object instance, CreationalContext<Object> creationalContext)Class<?>getBeanClass()StringgetId()Set<InjectionPoint>getInjectionPoints()StringgetName()Set<Annotation>getQualifiers()Class<? extends Annotation>getScope()Set<Class<? extends Annotation>>getStereotypes()Set<Type>getTypes()booleanisAlternative()booleanisNullable()
-
-
-
Constructor Detail
-
DynamicParamValueProducer
public DynamicParamValueProducer(Type type)
Construct dynamic param value producer for given type.- Parameters:
type- Type to construct dynamic param value producer for.
-
-
Method Detail
-
getBeanClass
public Class<?> getBeanClass()
- Specified by:
getBeanClassin interfaceBean<Object>
-
getTypes
public Set<Type> getTypes()
- Specified by:
getTypesin interfaceBeanAttributes<Object>
-
create
public Object create(CreationalContext<Object> creationalContext)
- Specified by:
createin interfaceContextual<Object>
-
getQualifiers
public Set<Annotation> getQualifiers()
- Specified by:
getQualifiersin interfaceBeanAttributes<Object>
-
getScope
public Class<? extends Annotation> getScope()
- Specified by:
getScopein interfaceBeanAttributes<Object>
-
getStereotypes
public Set<Class<? extends Annotation>> getStereotypes()
- Specified by:
getStereotypesin interfaceBeanAttributes<Object>
-
getInjectionPoints
public Set<InjectionPoint> getInjectionPoints()
- Specified by:
getInjectionPointsin interfaceBean<Object>
-
isAlternative
public boolean isAlternative()
- Specified by:
isAlternativein interfaceBeanAttributes<Object>
-
isNullable
public boolean isNullable()
- Specified by:
isNullablein interfaceBean<Object>
-
getName
public String getName()
- Specified by:
getNamein interfaceBeanAttributes<Object>
-
destroy
public void destroy(Object instance, CreationalContext<Object> creationalContext)
- Specified by:
destroyin interfaceContextual<Object>
-
getId
public String getId()
- Specified by:
getIdin interfacePassivationCapable
-
-