/** * Overrides findClass to first look in the parent class loader, * then try loading the class from the plugin file system. */ protected Class<?> findClass(String name) throws ClassNotFoundException { // Try loading the class from the file system. byte[] b = loadClassData(name); return defineClass(name, b, 0, b.length); }
/** * Load the class data from the file system */ private byte[] loadClassData(String name) throws ClassNotFoundException { if (pluginDirectory == null) { pluginDirectory = DefaultControllerEnvironment.libPath + File.separator + "controller"; } try { return loadClassFromDirectory(name); } catch (Exception e) { try { return loadClassFromJAR(name); } catch (IOException e2) { throw new ClassNotFoundException(name, e2); } } }
/** * Load the class data from the file system */ private byte[] loadClassData(String name) throws ClassNotFoundException { if (pluginDirectory == null) { pluginDirectory = DefaultControllerEnvironment.libPath + File.separator + "controller"; } try { return loadClassFromDirectory(name); } catch (Exception e) { try { return loadClassFromJAR(name); } catch (IOException e2) { throw new ClassNotFoundException(name, e2); } } }
/** * Overrides findClass to first look in the parent class loader, * then try loading the class from the plugin file system. */ protected Class findClass(String name) throws ClassNotFoundException { // Try loading the class from the file system. byte[] b = loadClassData(name); return defineClass(name, b, 0, b.length); }
/** * Load the class data from the file system */ private byte[] loadClassData(String name) throws ClassNotFoundException { if (pluginDirectory == null) { pluginDirectory = DefaultControllerEnvironment.libPath + File.separator + "controller"; } try { return loadClassFromDirectory(name); } catch (Exception e) { try { return loadClassFromJAR(name); } catch (IOException e2) { throw new ClassNotFoundException(name, e2); } } }
/** * Overrides findClass to first look in the parent class loader, * then try loading the class from the plugin file system. */ protected Class<?> findClass(String name) throws ClassNotFoundException { // Try loading the class from the file system. byte[] b = loadClassData(name); return defineClass(name, b, 0, b.length); }
/** * Load the class data from the file system */ private byte[] loadClassData(String name) throws ClassNotFoundException { if (pluginDirectory == null) { pluginDirectory = DefaultControllerEnvironment.libPath + File.separator + "controller"; } try { return loadClassFromDirectory(name); } catch (Exception e) { try { return loadClassFromJAR(name); } catch (IOException e2) { throw new ClassNotFoundException(name, e2); } } }
/** * Overrides findClass to first look in the parent class loader, * then try loading the class from the plugin file system. */ protected Class<?> findClass(String name) throws ClassNotFoundException { // Try loading the class from the file system. byte[] b = loadClassData(name); return defineClass(name, b, 0, b.length); }