Class DefaultLifecycleCallbackInvoker<T>
- java.lang.Object
-
- org.jboss.weld.injection.producer.DefaultLifecycleCallbackInvoker<T>
-
- Type Parameters:
T
-
- All Implemented Interfaces:
LifecycleCallbackInvoker<T>
public class DefaultLifecycleCallbackInvoker<T> extends Object implements LifecycleCallbackInvoker<T>
If the component is not intercepted this implementation takes care of invoking its lifecycle callback methods. If the component is interception,PostConstruct
/PreDestroy
invocation is delegated to the intercepting proxy.- Author:
- Jozef Hartinger
-
-
Constructor Summary
Constructors Constructor Description DefaultLifecycleCallbackInvoker(EnhancedAnnotatedType<T> type)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
hasPostConstructMethods()
boolean
hasPreDestroyMethods()
static <T> DefaultLifecycleCallbackInvoker<T>
of(EnhancedAnnotatedType<T> type)
void
postConstruct(T instance, Instantiator<T> instantiator)
void
preDestroy(T instance, Instantiator<T> instantiator)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jboss.weld.injection.producer.LifecycleCallbackInvoker
hasPostConstructCallback
-
-
-
-
Constructor Detail
-
DefaultLifecycleCallbackInvoker
public DefaultLifecycleCallbackInvoker(EnhancedAnnotatedType<T> type)
-
-
Method Detail
-
of
public static <T> DefaultLifecycleCallbackInvoker<T> of(EnhancedAnnotatedType<T> type)
-
postConstruct
public void postConstruct(T instance, Instantiator<T> instantiator)
- Specified by:
postConstruct
in interfaceLifecycleCallbackInvoker<T>
-
preDestroy
public void preDestroy(T instance, Instantiator<T> instantiator)
- Specified by:
preDestroy
in interfaceLifecycleCallbackInvoker<T>
-
hasPreDestroyMethods
public boolean hasPreDestroyMethods()
- Specified by:
hasPreDestroyMethods
in interfaceLifecycleCallbackInvoker<T>
-
hasPostConstructMethods
public boolean hasPostConstructMethods()
- Specified by:
hasPostConstructMethods
in interfaceLifecycleCallbackInvoker<T>
-
-