T - the class of the bean instancepublic interface ContextualLifecycle<T>
BeanBuilder and ImmutableBean to allow control
of the creation and destruction of a custom bean.| Modifier and Type | Method and Description |
|---|---|
T |
create(javax.enterprise.inject.spi.Bean<T> bean,
javax.enterprise.context.spi.CreationalContext<T> creationalContext)
Callback invoked by a created bean when
Contextual.create(CreationalContext) is called. |
void |
destroy(javax.enterprise.inject.spi.Bean<T> bean,
T instance,
javax.enterprise.context.spi.CreationalContext<T> creationalContext)
Callback invoked by a created bean when
Contextual.destroy(Object, CreationalContext) is called. |
T create(javax.enterprise.inject.spi.Bean<T> bean, javax.enterprise.context.spi.CreationalContext<T> creationalContext)
Contextual.create(CreationalContext) is called.bean - the bean initiating the callbackcreationalContext - the context in which this instance was createdvoid destroy(javax.enterprise.inject.spi.Bean<T> bean, T instance, javax.enterprise.context.spi.CreationalContext<T> creationalContext)
Contextual.destroy(Object, CreationalContext) is called.bean - the bean initiating the callbackinstance - the contextual instance to destroycreationalContext - the context in which this instance was createdCopyright © 2014 JBoss, a division of Red Hat. All Rights Reserved.