Interface WeldCreationalContext<T>

All Superinterfaces:
jakarta.enterprise.context.spi.CreationalContext<T>

public interface WeldCreationalContext<T> extends jakarta.enterprise.context.spi.CreationalContext<T>
Extended version of CreationalContext which gives the integrator additional control over the process of constructing an instance.
Author:
Jozef Hartinger
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Indicates whether Weld-managed AroundConstruct interceptors are suppressed.
    void
    Register a callback which is notified of component construction.
    void
    By default Weld takes care of AroundConstruct interceptors of a component instance which are bound to the component using interceptor bindings or the Interceptors annotation.

    Methods inherited from interface jakarta.enterprise.context.spi.CreationalContext

    push, release
  • Method Details

    • setConstructorInterceptionSuppressed

      void setConstructorInterceptionSuppressed(boolean value)
      By default Weld takes care of AroundConstruct interceptors of a component instance which are bound to the component using interceptor bindings or the Interceptors annotation. This may not be desired should an integrator want to manage these interceptors themselves. In that case this switch may be used to suppress Weld management of AroundConstruct interceptors. In that case an integrator is responsible for performing AroundConstruct interception.
      Parameters:
      value - the value
      See Also:
    • isConstructorInterceptionSuppressed

      boolean isConstructorInterceptionSuppressed()
      Indicates whether Weld-managed AroundConstruct interceptors are suppressed.
      Returns:
      true if Weld-managed AroundConstruct interceptors are suppressed
      See Also:
    • registerAroundConstructCallback

      void registerAroundConstructCallback(AroundConstructCallback<T> callback)
      Register a callback which is notified of component construction. This callback allows an integrator to perform additional tasks (e.g. invoking interceptors bound using the deployment descriptor) around constructor invocation. AroundConstructCallbacks are invoked in the order in which they were registered.
      Parameters:
      callback - the callback