Class RequestScopedBeanInterceptorHandler

java.lang.Object
org.apache.webbeans.intercept.NormalScopedBeanInterceptorHandler
org.apache.webbeans.intercept.RequestScopedBeanInterceptorHandler
All Implemented Interfaces:
jakarta.inject.Provider, Serializable

public class RequestScopedBeanInterceptorHandler extends NormalScopedBeanInterceptorHandler

This is a Provider especially made for @RequestScoped beans used in web applications.

Since there is only one single contextual instance of an @RequestScoped bean per thread, we can simply cache this instance inside our bean. We only need to reload this instance if it is null or if the thread ends.

See Also:
  • Constructor Details

    • RequestScopedBeanInterceptorHandler

      public RequestScopedBeanInterceptorHandler(jakarta.enterprise.inject.spi.BeanManager beanManager, jakarta.enterprise.inject.spi.Bean<?> bean)
      Creates a new handler.
  • Method Details