beanManager.getWebBeansContext().getBeanArchiveService().getBeanArchiveInformation(beanArchiveUrl); if (!beanArchiveInfo.isClassExcluded(beanClass.getName())) {
/** * Ensures that all ThreadLocals, which could have been set in this * (shutdown-) Thread, are removed in order to prevent memory leaks. */ private void cleanupShutdownThreadLocals() { contextsService.removeThreadLocals(); }
@Override public void init(final Object context) { if (delegate != null) { delegate.init(context); } }
public static void startContexts(final ContextsService contextsService, final ServletContext servletContext, final HttpSession session) throws Exception { contextsService.startContext(Singleton.class, null); contextsService.startContext(ApplicationScoped.class, null); contextsService.startContext(SessionScoped.class, session); contextsService.startContext(RequestScoped.class, null); contextsService.startContext(ConversationScoped.class, null); }
public void destroyRequest(@Observes After event) { ContextsService service = this.lifecycle.get().getContextService(); service.endContext(ConversationScoped.class, null); service.endContext(RequestScoped.class, null); }
@Override public void requestDestroyed(final ServletRequestEvent sre) { owb.endContext(RequestScoped.class, sre); } }
@Override public void stop() { lifecycle.stopApplication(null); }
@Override public BeanManager getBeanManager() { return lifecycle.getBeanManager(); }
public BeanArchiveFilter(BeanArchiveInformation beanArchiveInfo, List<String> urlClasses, Filter userFilter) { this.beanArchiveInfo = beanArchiveInfo; this.urlClasses = urlClasses; this.userFilter = userFilter; BeanDiscoveryMode discoveryMode = beanArchiveInfo.getBeanDiscoveryMode(); scanNone = BeanDiscoveryMode.NONE == discoveryMode; }
public static BeanDiscoveryMode getByOrdinal(int ordinal) { for (BeanDiscoveryMode beanDiscoveryMode : values()) { if (beanDiscoveryMode.getOrdinal() == ordinal) { return beanDiscoveryMode; } } return null; }
public static void clearInstances(Object key) { singletonService.clear(key); }
private String getBDABeansXMLPath(Class<?> injectionPointBeanClass) { if (injectionPointBeanClass == null) { return null; } ScannerService scannerService = webBeansContext.getScannerService(); BDABeansXmlScanner beansXMLScanner = scannerService.getBDABeansXmlScanner(); return beansXMLScanner.getBeansXml(injectionPointBeanClass); }
@Override protected void beforeStartApplication(Object startupObject) { this.scannerService.init(startupObject); }
public static void startContexts(final ContextsService contextsService, final ServletContext servletContext, final HttpSession session) throws Exception { contextsService.startContext(SessionScoped.class, session); contextsService.startContext(RequestScoped.class, null); contextsService.startContext(ConversationScoped.class, null); }
public void beforeUndeployment(@Observes BeforeUnDeploy event) { ContextsService service = lifecycle.get().getContextService(); service.endContext(ApplicationScoped.class, null); }
@Override public BeanManager getBeanManager() { if (lifecycle == null) { return null; } return lifecycle.getBeanManager(); }
/** * Ensures that all ThreadLocals, which could have been set in this * requests Thread, are removed in order to prevent memory leaks. */ private void cleanupRequestThreadLocals() { if (contextsService != null) { contextsService.removeThreadLocals(); } }
@Override public void init(final Object context) { if (delegate != null) { delegate.init(context); } }
@Override public void requestInitialized(final ServletRequestEvent sre) { owb.startContext(RequestScoped.class, sre); }
@Override public BeanManager getBeanManager() { if (lifecycle == null) { return null; } return lifecycle.getBeanManager(); }