Examples of URLClassLoaderFirst


Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

            if (serviceInfo.classpath != null && serviceInfo.classpath.length > 0) {
                final URL[] urls = new URL[serviceInfo.classpath.length];
                for (int i = 0; i < serviceInfo.classpath.length; i++) {
                    urls[i] = serviceInfo.classpath[i].toURL();
                }
                loader = new URLClassLoaderFirst(urls, loader);
                customLoader = true;
            }
        } catch (final MalformedURLException e) {
            throw new OpenEJBException("Unable to create a classloader for " + serviceInfo.id, e);
        }
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

    public static URL getUrlKeyCached(final String appId, final File file) {
        return localUrlCache.getUrlKeyCached(appId, file);
    }

    public static URLClassLoader createClassLoaderFirst(final String appId, final URL[] urls, final ClassLoader parent) {
        return cacheClassLoader(appId, new URLClassLoaderFirst(localUrlCache.cacheUrls(appId, urls), parent));
    }
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

                    final String[] paths = cp.split(File.pathSeparator);
                    final List<URL> urls = new ArrayList<URL>();
                    for (final String path : paths) {
                        urls.add(new File(PropertyPlaceHolderHelper.value(ProvisioningUtil.realLocation(path))).toURI().normalize().toURL());
                    }
                    deployments.setClasspath(new URLClassLoaderFirst(urls.toArray(new URL[urls.size()]), ParentClassLoaderFinder.Helper.get()));
                }
            }

            return object;
        } catch (final Exception e) {
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

        }

        // enhancement

        final ClassLoader tccl = Thread.currentThread().getContextClassLoader();
        final ClassLoader fakeClassLoader = new URLClassLoaderFirst(usedUrls.toArray(new URL[usedUrls.size()]), event.getParentClassLoader());

        LOGGER.info("Enhancing url(s): " + usedUrls);

        Thread.currentThread().setContextClassLoader(fakeClassLoader);
        try {
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

        final ClassLoader loader;
        if (!WEB_INF.equals(prefix)) {
            loader = new SWClassLoader("", new URLClassLoader(urls, parent), archive);
        } else {
            loader = new SWClassLoader("/WEB-INF/classes/", new URLClassLoaderFirst(urls, parent), archive);
        }
        final URLClassLoader tempClassLoader = ClassLoaderUtil.createTempClassLoader(loader);

        final AppModule appModule = new AppModule(loader, archive.getName());
        if (WEB_INF.equals(prefix)) {
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

    public static URL getUrlKeyCached(final String appId, final File file) {
        return localUrlCache.getUrlKeyCached(appId, file);
    }

    public static URLClassLoader createClassLoaderFirst(final String appId, final URL[] urls, final ClassLoader parent) {
        return cacheClassLoader(appId, new URLClassLoaderFirst(localUrlCache.cacheUrls(appId, urls), parent));
    }
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

                    final String[] paths = cp.split(File.pathSeparator);
                    final List<URL> urls = new ArrayList<URL>();
                    for (final String path : paths) {
                        urls.add(new File(PropertyPlaceHolderHelper.value(ProvisioningUtil.realLocation(path))).toURI().normalize().toURL());
                    }
                    deployments.setClasspath(new URLClassLoaderFirst(urls.toArray(new URL[urls.size()]), ParentClassLoaderFinder.Helper.get()));
                }
            }

            return object;
        } catch (final Exception e) {
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

            if (serviceInfo.classpath != null && serviceInfo.classpath.length > 0) {
                final URL[] urls = new URL[serviceInfo.classpath.length];
                for (int i = 0; i < serviceInfo.classpath.length; i++) {
                    urls[i] = serviceInfo.classpath[i].toURL();
                }
                loader = new URLClassLoaderFirst(urls, loader);
                customLoader = true;
            }
        } catch (final MalformedURLException e) {
            throw new OpenEJBException("Unable to create a classloader for " + serviceInfo.id, e);
        }
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

            if (serviceInfo.classpath != null && serviceInfo.classpath.length > 0) {
                final URL[] urls = new URL[serviceInfo.classpath.length];
                for (int i = 0; i < serviceInfo.classpath.length; i++) {
                    urls[i] = serviceInfo.classpath[i].toURL();
                }
                loader = new URLClassLoaderFirst(urls, loader);
                customLoader = true;
            }
        } catch (final MalformedURLException e) {
            throw new OpenEJBException("Unable to create a classloader for " + serviceInfo.id, e);
        }
View Full Code Here

Examples of org.apache.openejb.util.classloader.URLClassLoaderFirst

    public static URL getUrlKeyCached(final String appId, final File file) {
        return localUrlCache.getUrlKeyCached(appId, file);
    }

    public static URLClassLoader createClassLoaderFirst(final String appId, final URL[] urls, final ClassLoader parent) {
        return cacheClassLoader(appId, new URLClassLoaderFirst(localUrlCache.cacheUrls(appId, urls), parent));
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.