/** * Sets bean enabled flag. * @param bean bean instance */ public void setInjectionTargetBeanEnableFlag(InjectionTargetBean<?> bean) { bean.setEnabled(isBeanEnabled(bean.getAnnotatedType(), bean.getStereotypes())); }
/** * Initializes the InjectionTarget Bean part. */ public InjectionTargetBean(WebBeansContext webBeansContext, WebBeansType webBeansType, AnnotatedType<T> annotatedType, BeanAttributes<T> beanAttributes, Class<T> beanClass, InjectionTargetFactory<T> factory) { super(webBeansContext, webBeansType, beanAttributes, beanClass, false); Asserts.assertNotNull(annotatedType, "AnnotatedType"); this.annotatedType = annotatedType; injectionTarget = factory.createInjectionTarget(this); setEnabled(true); }