class PluginClassLoader extends URLClassLoader {

    @Override
    public Class<?> loadClass(String name) throws ClassNotFoundException {
        logger.trace("Received request to load class '{}'", name);
        synchronized (getClassLoadingLock(name)) {
            if (name.startsWith(JAVA_PACKAGE_PREFIX) || name.startsWith(JAVAX_PACKAGE_PREFIX)) {
                return findSystemClass(name);
            }

            boolean isWhitePrefixes = fromWhitePrefix(name);
            boolean isExcludePrefixed = fromExcludePrefix(name);

            // if the class is part of the plugin engine use parent class loader
            if (!isWhitePrefixes && isExcludePrefixed) {
                return getParent().loadClass(name);
            }

            // check whether it's already been loaded
            Class<?> loadedClass = findLoadedClass(name);
            if (loadedClass != null) {
                logger.debug("Found loaded class '{}'", name);
                return loadedClass;
            }

            // nope, try to load locally
            try {
                loadedClass = findClass(name);
                logger.debug("Found class '{}' in plugin classpath", name);
                return loadedClass;
            } catch (ClassNotFoundException e) {
                // try next step
            }

            // use the standard ClassLoader (which follows normal parent delegation)
            return super.loadClass(name);
        }
    }

    public  PluginClassLoader(URL[] urls, ClassLoader parent, String[] whitePrefix, String[] excludePreifx);

}