Package org.apache.webbeans.spi

Examples of org.apache.webbeans.spi.BeanArchiveService


            // here for ears we need to skip classes in the parent classloader
            final ClassLoader scl = ClassLoader.getSystemClassLoader();
            final boolean filterByClassLoader = "true".equals(SystemInstance.get().getProperty(OPENEJB_CDI_FILTER_CLASSLOADER, "true"));

            final BeanArchiveService beanArchiveService = webBeansContext.getBeanArchiveService();
            final boolean openejb = OpenEJBBeanInfoService.class.isInstance(beanArchiveService);

            for (final BeansInfo.BDAInfo next : beans.bdas) {
                final BeanArchiveService.BeanArchiveInformation information;
                if (openejb) {
                    final OpenEJBBeanInfoService beanInfoService = OpenEJBBeanInfoService.class.cast(beanArchiveService);
                    information = beanInfoService.createBeanArchiveInformation(beans, classLoader, next.discoveryMode == null? "ALL" : next.discoveryMode); // this fallback is 100% for tests, TODO: get rid of it (AppComposer)
                    // TODO: log a warn is discoveryModes.get(key) == null
                    try {
                        beanInfoService.getBeanArchiveInfo().put(next.uri == null ? null : next.uri.toURL(), information);
                    } catch (final MalformedURLException e) {
                        throw new IllegalStateException(e);
                    }
                } else {
                    try {
                        information = beanArchiveService.getBeanArchiveInformation(next.uri.toURL());
                    } catch (MalformedURLException e) {
                        throw new IllegalStateException(e);
                    }
                }
View Full Code Here


            // here for ears we need to skip classes in the parent classloader
            final ClassLoader scl = ClassLoader.getSystemClassLoader();
            final boolean filterByClassLoader = "true".equals(SystemInstance.get().getProperty(OPENEJB_CDI_FILTER_CLASSLOADER, "true"));

            final BeanArchiveService beanArchiveService = webBeansContext.getBeanArchiveService();
            final boolean openejb = OpenEJBBeanInfoService.class.isInstance(beanArchiveService);

            for (final BeansInfo.BDAInfo next : beans.bdas) {
                final BeanArchiveService.BeanArchiveInformation information;
                if (openejb) {
                    final OpenEJBBeanInfoService beanInfoService = OpenEJBBeanInfoService.class.cast(beanArchiveService);
                    information = beanInfoService.createBeanArchiveInformation(beans, classLoader, next.discoveryMode == null? "ALL" : next.discoveryMode); // this fallback is 100% for tests, TODO: get rid of it (AppComposer)
                    // TODO: log a warn is discoveryModes.get(key) == null
                    try {
                        beanInfoService.getBeanArchiveInfo().put(next.uri == null ? null : next.uri.toURL(), information);
                    } catch (final MalformedURLException e) {
                        throw new IllegalStateException(e);
                    }
                } else {
                    try {
                        information = beanArchiveService.getBeanArchiveInformation(next.uri.toURL());
                    } catch (MalformedURLException e) {
                        throw new IllegalStateException(e);
                    }
                }
View Full Code Here

TOP

Related Classes of org.apache.webbeans.spi.BeanArchiveService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.